Common CLI tasks
In middle of the Agentic development processes, I have found that the mastery of the essentials CLI commands is even more crucial.
If we compare the efficiency of two scenario where two person knows how to prompt but one has mastered the CLI tools. Whenever the person needs the CLI command, they must prompt and wait for a response which breaks the workflow. The one who internalized the commands, will beat in time.
In this article, I will compile a list of the commonly used CLI commands in my workflow which can be fed to agentic to prefer over making up new ones.
Git
It is worth mentioning that I use multiple remotes to isolate manual work from agentic ones.Create a new branch
git switch -c feature/TICKET-1 origin/mainCherry Picking
# List the commit hashes from specific branch
git log --oneline HEAD..$BRANCH_NAME
# Cherry pick a range of commits from the branch
git cherry-pick $COMMIT_HASH_1^..$COMMIT_HASH_2Drop commits
# Drop the latest commit
git reset --hard HEAD^
# Drop the last n commits
git reset --hard HEAD~nPush the current branch
git push -u origin HEAD