{"id":13796154,"url":"https://github.com/vigneshwaranr/bd","last_synced_at":"2025-05-13T00:30:43.058Z","repository":{"id":3039807,"uuid":"4060587","full_name":"vigneshwaranr/bd","owner":"vigneshwaranr","description":"Quickly go back to a parent directory in linux instead of typing \"cd ../../..\" repeatedly","archived":false,"fork":false,"pushed_at":"2022-09-15T02:40:08.000Z","size":191,"stargazers_count":921,"open_issues_count":27,"forks_count":64,"subscribers_count":34,"default_branch":"master","last_synced_at":"2024-08-03T23:06:25.143Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/vigneshwaranr.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-04-18T05:48:48.000Z","updated_at":"2024-07-18T10:32:16.000Z","dependencies_parsed_at":"2023-01-11T16:14:01.157Z","dependency_job_id":null,"html_url":"https://github.com/vigneshwaranr/bd","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vigneshwaranr%2Fbd","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vigneshwaranr%2Fbd/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vigneshwaranr%2Fbd/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vigneshwaranr%2Fbd/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vigneshwaranr","download_url":"https://codeload.github.com/vigneshwaranr/bd/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225159846,"owners_count":17430191,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-03T23:01:06.841Z","updated_at":"2024-11-18T10:31:06.365Z","avatar_url":"https://github.com/vigneshwaranr.png","language":"Shell","readme":"# bd\n\n#### Description\nQuickly go back to a specific parent directory in bash instead of typing \"cd ../../..\" redundantly.\n\n---\n\n**Installation**\n\n***For OS X/macOS***\n\nUsing [MacPorts](https://ports.macports.org/port/bd):\n\n```bash\nsudo port install bd\n```\n\n***For Debian/Ubuntu***\n\nPackages available here:\n\nhttps://tracker.debian.org/pkg/bd\n\nhttps://launchpad.net/ubuntu/+source/bd\n\n***For Arch Linux***\n\nAUR packages available here:\n\nhttps://aur.archlinux.org/packages/bd\n\nhttps://aur.archlinux.org/packages/bd-git\n\n***For other OS***\n\n```shell\nwget --no-check-certificate -O /usr/local/bin/bd https://raw.github.com/vigneshwaranr/bd/master/bd\nchmod +rx /usr/local/bin/bd\necho 'alias bd=\". bd -si\"' \u003e\u003e ~/.bashrc\nsource ~/.bashrc\n\n# If you need autocomplete support, follow these two steps\nwget -O /etc/bash_completion.d/bd https://raw.github.com/vigneshwaranr/bd/master/bash_completion.d/bd\nsource /etc/bash_completion.d/bd\n```\n\nTo enable case-sensitive directory name matching, use `-s` instead of `-si` in the alias.\n\n---\n\n**How to use:**\n\nIf you are in this path `/home/user/project/src/org/main/site/utils/file/reader/whatever`\nand you want to go to `site` directory quickly, \n\nthen just type:\n     `bd site`\n\nIn fact, You can simply type \u003ccode\u003ebd *\\\u003cstarting few letters\\\u003e*\u003c/code\u003e like `bd s` or `bd si`\n\nIf there are more than one directories with same name up in the hierarchy, bd will take you to the closest. (Not considering the immediate parent.)\n\n---\n\n**Other uses:**\n\nUsing bd within backticks (\u003ccode\u003e\\`bd \\\u003cletter(s)\\\u003e\\`\u003c/code\u003e) prints out the path without changing the current directory.\n\nYou can take advantage of that by combining \u003ccode\u003e\\`bd \\\u003cletter(s)\\\u003e\\`\u003c/code\u003e with other commands such as ls, ln, echo, zip, tar etc..\n\n**Example:**\n\n1. If you just want to list the contents of a parent directory,\n   without going there, then you can use:\n\t\t\u003ccode\u003els \\`bd p\\`\u003c/code\u003e\n   in the given example, it will list the contents of \n             `/home/user/project/`\n\n2. If you want to execute a file somewhere in a parent directory,\n            \u003ccode\u003e\\`bd p\\`/build.sh\u003c/code\u003e\n   will execute `/home/user/project/build.sh` while not changing the\n   current directory.\n\n3. If you reside in `/home/user/project/src/org/main/site/utils/file/reader/whatever`\n   and want to change to `/home/user/project/test`, then try\n            \u003ccode\u003ecd \\`bd p\\`/test\u003c/code\u003e\n\n---\n\n**Screenshot:**\n![bd screenshot](https://raw.github.com/vigneshwaranr/bd/master/screenshot/bd.png \"Screenshot that shows some of several ways to use bd\")\n\n\n---\n\n**Thanks:**\n* [@jaysh](https://github.com/jaysh) - Autocomplete support\n* [@rmhsilva](https://github.com/rmhsilva) - Case-Insensitive directory name matching\n* [@janosgyerik](https://github.com/janosgyerik) - Test cases, BSD support\n* [@phls](https://github.com/phls) - Packaging bd for Debian\n\n---\n\n**See also:**\n* [Tarrasch/zsh-bd](https://github.com/Tarrasch/zsh-bd) - bd for zsh\n* [0rax/fish-bd](https://github.com/0rax/fish-bd) - bd for [fish](http://fishshell.com/) shell\n* [rvraghav93/win-bd](https://github.com/rvraghav93/win-bd) - bd for command prompt\n* [peterwvj/eshell-up](https://github.com/peterwvj/eshell-up) - bd inspired command for Emacs' eshell\n* [alebcay/awesome-shell](https://github.com/alebcay/awesome-shell) - A curated list of awesome command-line frameworks, toolkits, guides and gizmos \n","funding_links":[],"categories":["Command-Line Productivity","Shell"],"sub_categories":["Directory Navigation"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvigneshwaranr%2Fbd","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvigneshwaranr%2Fbd","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvigneshwaranr%2Fbd/lists"}