bashmarks
Bookmark and jump to directories easily
TLDR
Add the bashmark aliases to your shell
List available bookmarks
Save the current directory as "bookmark_name"
Go to a bookmarked directory
Print a bookmarked directory's contents
Delete a bookmark
SYNOPSIS
mark {alias}
jump {alias}
list
delete {alias}
rename {old_alias} {new_alias}
PARAMETERS
mark {alias}
Bookmarks the current directory with the given alias. If an alias exists, it's overwritten.
jump {alias}
Changes the current directory to the directory associated with the given alias. If the alias is not defined, it will output an error message.
list
Lists all currently defined bookmarks and their corresponding directories or commands.
delete {alias}
Deletes the bookmark associated with the given alias.
rename {old_alias} {new_alias}
Renames the bookmark from {old_alias} to {new_alias}
DESCRIPTION
Bashmarks is a simple, command-line bookmarking utility for the bash shell. It allows you to save commonly used directories and commands, then quickly jump to them later. It essentially provides a way to create shortcuts directly within your shell, saving you typing and improving workflow efficiency. Instead of memorizing long paths or frequently used command sequences, you can assign them a short, memorable alias using bashmarks. Navigating to a bookmarked directory or executing a bookmarked command becomes as simple as typing a short command and the alias. The bookmarks are stored persistently, so they are available across shell sessions. Bashmarks improves efficiency by reducing the time spent navigating directories and re-typing commands.
CAVEATS
Bashmarks relies on the bash shell. It might not function correctly or at all in other shells (e.g., zsh, fish) without modification. Bashmarks modifies the shell environment (specifically by adding a function to your `.bashrc` or `.bash_profile`), ensure that this is acceptable before installation. Error handling is generally basic; invalid aliases or non-existent bookmarks may lead to unexpected behavior.
INSTALLATION
Bashmarks is typically installed by sourcing a bash script (e.g., `bashmarks.sh`) into your shell environment. This usually involves downloading the script and then adding a line like `source /path/to/bashmarks.sh` to your `.bashrc` or `.bash_profile` file. After restarting your shell or sourcing the file directly, the `mark`, `jump`, `list`, `delete` and `rename` commands become available.
UNDER THE HOOD
Internally, bashmarks relies on storing bookmark data (alias-directory pairs) in a file, usually in your home directory. The `mark` command updates this file, the `jump` command reads from it, and the `list` and `delete` commands manipulate it. The implementation is generally straightforward bash scripting.
HISTORY
Bashmarks's development history is less formally tracked than core system utilities. It's typically a personal or small-team project aimed at improving shell workflow. Usage is common among developers and system administrators who frequently work with the command line and need to navigate complex directory structures or repeat common command sequences. It gained popularity as a readily-available and easily-installable tool for enhancing shell productivity.