Modern `git` can use `submodule` option `update` instead of `foreach`
to achieve approximately similar outcome.
To allows call without assuming that all submodules will have default
branch as `master`, the preferred approach would be to call
`git submodule update --remote --recursive` after registering the
correct branch for submodule in `.gitmodules`:
```
git config -f .gitmodules submodule.<path>.branch <branch>
```
For more discussion, see: https://stackoverflow.com/a/33835815
Signed-off-by: Indrajit Raychaudhuri <irc@indrajit.com>
Changes:
- Prefer longer form of git switch for better clarity.
- Move `-S` (`--gpg-sign`) in all the alias definitions to the end to
allow custom keyid.
- Simplify operations in helper functions git native calls.
- Apply minor reformatting and rearranging.
* Add some new git aliases, modify a few more.
* Add `gbV` command to show more verbose git branch info.
* Add `gcam` to make it possible to execute `gca; gcm '<your message
here>'` more simply.
* Add `gii` command to temporarily untrack (ignore) a file.
* Add `giI` command to uningore a file.
* Change alias of `gbl` to `gbv`. Personally, I think aliases that
include a switch in the command should include the switch in the alias
if possible. This makes them easier to remember.
* Change alias of `gbL` to `gba`. I think the `-a` switch is more
salient to what this alias does than the `-v`. Furthermore, with this
PR there are already `gbv` and `gbV` aliases, so those are out.
* Change implementation of `gCl` alias to use built-in capabilities of
git, rather than sed.
* Rename gbx and gbX to gbd and gbD respectively
* Mostly revert alias changes
* Add gbr and gbR aliases to gbm and gbM commands
Fix a bug introduced in d4a5bed.
Though '--mixed' is the default for 'git reset', using it with paths
returns the following warning.
warning: --mixed with paths is deprecated; use 'git reset -- <paths>'
instead.