[FEATURE] automate `branch` and `commit hash` CLI options
See original GitHub issueIs your feature request related to a problem? Please describe.
Automatically detect branch name and commit hash when reassure
detects that it is run inside a Git repo.
Describe the solution you’d like
Basically make current --branch $(git branch --show-current) --commitHash $(git rev-parse HEAD)
options automatic when user is using Git.
Kept the existing CLI options to allow user to override the default values and/or support other source controls systems.
Invoke git
binary commands using node child_process
(?) API to avoid external deps.
Describe alternatives you’ve considered
- Instead of invoking external binary use some node package like
simple-git
to communicate with GIT repo.
Additional context
Issue Analytics
- State:
- Created a year ago
- Comments:8 (8 by maintainers)
Top Results From Across the Web
Powerful Git Macros For Automating Everyday Workflows
These commands can be especially useful when you're trying to find the right commit hash for a rebase, such as when using git...
Read more >4 ways to create a Git branch quickly by example
Here we'l show you four different ways to create a Git branch, be it from the current branch, from a tag or from...
Read more >git-commit-id-maven-plugin/using-the-plugin.md at master
git.local.branch.behind, Represents the count of commits that your local branch is behind in perspective to the remote branch (usually the case when there...
Read more >git-merge Documentation - Git
Then " git merge topic " will replay the changes made on the topic branch since ... the -m option from the command...
Read more >Git Cherry Pick: Getting the Exact Commit You Want | CloudBees
git commit -am “Update file.txt”. The commands above do the following: Create a new branch and switch to it. Add a new file...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Resolved by #211
A good place for checking these values is the very beginning of “run” method in measure.ts in CLI package