{"id":15938815,"url":"https://github.com/ticky/batfiles","last_synced_at":"2025-10-06T15:06:09.476Z","repository":{"id":145549283,"uuid":"58076997","full_name":"ticky/batfiles","owner":"ticky","description":"A simple set of unix-like and helpful macros for dealing with the Windows command prompt.","archived":false,"fork":false,"pushed_at":"2016-05-04T19:03:05.000Z","size":9,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-04T06:43:49.115Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Lua","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ticky.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-05-04T19:02:54.000Z","updated_at":"2024-06-14T03:23:49.000Z","dependencies_parsed_at":"2023-05-25T20:15:23.592Z","dependency_job_id":null,"html_url":"https://github.com/ticky/batfiles","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ticky%2Fbatfiles","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ticky%2Fbatfiles/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ticky%2Fbatfiles/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ticky%2Fbatfiles/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ticky","download_url":"https://codeload.github.com/ticky/batfiles/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240266872,"owners_count":19774081,"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-10-07T05:42:13.762Z","updated_at":"2025-10-06T15:06:04.425Z","avatar_url":"https://github.com/ticky.png","language":"Lua","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Batfiles\n\nA simple set of unix-like and helpful macros for dealing with the Windows command prompt.\n\n## Features\n\n* prompt updated with working git branch and status\n* useful aliases for git and more\n* download files from the command line\n* 2 line prompt for readability\n* [base16](https://github.com/chriskempson/base16) colour scheme for Windows Command Prompt\n\n## Requirements\n\n* **`git`**  \n  _Well, you're here, aren't you?_\n* **[Clink](https://code.google.com/p/clink/)**  \n  _Brings Bash-style completion and history to the Windows command prompt_\n\n## Setup\n\n1. Clone this repo into your `%USERPROFILE%/batfiles` directory;\n   `git clone https://github.com/geoffstokes/batfiles.git %USERPROFILE%/batfiles`\n2. Run `setup.bat` from the `batfiles` directory.\n\n## Usage\n* `~`: Go to your user profile directory\n* `cd`: Replaced with `chdir /D`, meaning it'll _just change drives when you bloody ask it to_\n* `clear`: clear the screen\n* `fn`: search recursively through the current directory and its subdirectories\n* Git shortcuts\n    * `ga`: `git add`\n    * `gb`: Show all local and remote branches (`git branch -av`)\n    * `gbp`: Show all unmerged branches, with their remote equivalents (if any. equivalent to `git branch -avv --no-merged`)\n    * `gc`: `git commit -v`\n    * `gco`: `git checkout`\n    * `gd`: `git diff`\n    * `gdc`: `git diff --cached`\n    * `gdh`: `git diff HEAD`\n    * `gf`: `git fetch`\n    * `gl`: `git log`\n    * `gp`: `git push`\n    * `gpl`: `git pull`\n    * `gr`: `git remote -v`\n    * `gs`: `git status`\n    * `gu`: `git up`\n* `ls`: run `dir` in a vaguely unix-like way (and get a message from Steve)\n* `ntget`: insanely simplistic file download utility (written in Powershell)\n* `source`: reload the `doskey` macro file\n* `x`: shortcut to exit\n\n## How\n\nThis uses `doskey` to set up macros by running it whenever a command prompt instance starts. Automatically running something on each command prompt load is achieved by setting the `AutoRun` key in `HKEY_CURRENT_USER\\Software\\Microsoft\\Command Processor` in the Registry.\n\nThese changes are per-user and can (and will) be expanded upon by adding commands (setting variables, etc) to `cmd_profile.bat` and/or adding aliases to `doskey.mcr`.\n\n`ntget` is a (very) simple PowerShell script which is called from a `doskey` macro.\n\n_**NOTE**: A previous version changed your PowerShell ExecutionPolicy to `RemoteSigned`. This is no longer the case. To restore the default policy, you can run this command from cmd; `powershell -Command \"\u0026 {Set-ExecutionPolicy -ExecutionPolicy Restricted}\"`_\n\nThe colours are overridden in the registry (and require you to have not customised them for any command prompt shortcut), and the improved prompt uses Clink.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fticky%2Fbatfiles","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fticky%2Fbatfiles","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fticky%2Fbatfiles/lists"}