• Stars
    star
    328
  • Rank 124,081 (Top 3 %)
  • Language
    Shell
  • License
    MIT License
  • Created almost 5 years ago
  • Updated 6 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Speed up your Git workflow. 🐠

GitNow CI Releases

Speed up your Git workflow. 🐠

GitNow contains a command set that provides high-level operations on the top of Git.
A Fish shell alternative inspired by git-friendly.

Install

Stable:

Paket

paket add joseluisq/[email protected]

Fisher

fisher install joseluisq/[email protected]

Fundle

fundle plugin joseluisq/gitnow --url '[email protected]:joseluisq/gitnow.git#tags/2.11.0'

Latest changes:

paket add joseluisq/gitnow

# Or
fisher install joseluisq/gitnow

# Or
fundle plugin joseluisq/gitnow

Note: Use that method if you don't want to wait for a new release.

Commands

Command Shortcut Description
gitnow Show available commands and version info.
Git
state Alt + S Show the working tree status in a compact way.
stage Alt + E Stage files in current working directory.
unstage Ctrl + E Unstage files in current working directory.
show Alt + M Show commit detail objects.
untracked Check for untracked files and directories.
commit Commit changes to the repository.
commit-all Alt + C Add and commit all changes to the repository.
tag List and create release tag versions following Semver 2.0.
pull Alt + D Pull changes from remote server but saving uncommitted changes.
push Alt + P Push commit changes to remote repository.
upstream Alt + U Commit all changes and push them to remote server.
move Moves from current branch to another but stashing your changes.
merge Merges a local branch into the active one.
assume Ignores changes in certain files temporarily.
logs Alt + L Shows logs in a fancy way.
Gitflow
feature (1) Alt + F Creates a new feature (Gitflow) branch from current branch.
hotfix (1) Alt + H Creates a new hotfix (Gitflow) branch from current branch.
bugfix (1) Creates a new bugfix (Gitflow) branch from current branch.
release (1) Creates a new release (Gitflow) branch from current branch.
Bonus
github Clone a GitHub repository using SSH.
bitbucket Clone a Bitbucket Cloud repository using SSH.

Note:

  • (1) This command key binding can creates a new branch taking as name some text of the clipboard (optional).

Tips

  • Skip the password request creating a SSH key for your Github or Bitbucket account.
  • SSH setup is required for using github and bitbucket commands.
  • Take advantage of keybindings in order to get faster operations.

Gitnow configuration file

To configure Gitnow just copy the .gitnow default file and place it in your home directory (~/.gitnow).

Options

The [ options ] section contains some options in order to adjust centain Gitnow behaviour.

For more details about the options please take a look at .gitnow file content.

Keybindings

The .gitnow file contains a [ keybindings ] section with default shortcuts (key-value pairs). But you can add, edit or remove keybindings on demand. If you want custom keybindings for your commands just run fish_key_reader in your terminal, then press the key or key's combinations to get the right characters sequence and finally set it to your preferred command in your ~/.gitnow file.

Usage

gitnow

Show available commands and version info.

gitnow

state

Show the working tree status in compact way.

state
Current working tree status:
## master...origin/master
 M README.md
 M conf.d/gitnow.fish

stage

Stage files in current working directory.

Note: This command does git add . by default. Add your git add flags as usual to overwrite it.

# a) git add . (by default)
stage
# b) custom 1
stage README.md LICENSE.md
# c) custom 2
stage . --ignore-errors

unstage

Unstage files in current working directory.

Note: This command does git reset . by default. Add your git reset flags as usual to overwrite it.

# a) git reset . (by default)
unstage
# b) custom 1
unstage README.md LICENSE.md
# c) custom 2
unstage --soft HEAD

show

Show commit detail objects.

Note: This command does git show --compact-summary HEAD by default. Add your git show flags as usual to overwrite it.

# a) Default
show
# b) Custom flags
show --compact-summary HEAD~1

untracked

Check for untracked files and directories that could be removed of current working directory.

Notes:

  • This command does git clean --dry-run -d only.
  • It doesn't remove anything, just makes a clean checking of files and directories that could be removed.
  • No flags are supported.
untracked
# Would remove .file1
# Would remove dir1/
# Would remove file2

commit

Commit changes to the repository.

Note: This command does git commit only. Add your git commit flags as usual to overwrite it.

commit
commit README.md
commit .
commit --amend

commit-all

Add and commit all changes to the repository.

Note: This command does stage and then commit .. No flags supported.

# stage && commit .
commit-all

tag

List and create release tag versions following The Semantic Versioning 2.0.0.

Show information about Tag options

tag -h                                                                                                                                          (13s 251ms)
# NAME
#       Gitnow: tag - List or tag commits following The Semantic Versioning 2.0.0 (Semver) [1]
#       [1] https://semver.org/
# EXAMPLES
#       List tags: tag
#       Custom tag: tag <my tag name>
#       Semver tag: tag --major
# OPTIONS:
#       Without options all tags are listed in a lexicographic order and tag names are treated as versions
#       -x --major         Tag auto-incrementing a major version number
#       -y --minor         Tag auto-incrementing a minor version number
#       -z --patch         Tag auto-incrementing a patch version number
#       -l --latest        Show only the latest Semver release tag version (no suffixed ones or others)
#       -h --help          Show information about the options for this command

List all available tags

Tags are listed in a lexicographic order and tag names are treated as versions.

tag

Get latest Semver release tag name

Note: This option gets only the latest Semver release version tag name but no any suffixed version ones or another kind of version names. The same apply when you create correlative Semver tags. See next section.

tag --latest

Create Semver correlative tag names

Note: Following commands take care about optional v prefixed tag names. So for example if a v1.0.0 is found as latest major then the next correlative tag name major will be v2.0.0. Otherwise for example if a 1.0.0 is found as latest minor then the next correlative tag name minor will be 1.1.0.

# Create a correlative Semver major tag
tag --major
# Create a correlative Semver minor tag
tag --minor
# Create a correlative Semver patch tag
tag --patch

Create custom tag names

tag <some tag name>

pull

Pull changes from remote server but saving uncommitted changes.

This command makes this for you:

  • Save your uncommitted changes locally using --autostash option.
  • Local changes you made will be rebased (---rebase option) on top of the remote changes.
  • Return your uncommitted changes locally again.

Auto mode:

  • pull
  • pull <branch_name>
  • pull <remote_origin> <branch_name>

Manual mode:

  • pull <remote_origin> <branch_name> --verbose
pull
πŸ“₯ Pulling changes
Arguments mode: Auto
Default arguments: --rebase --autostash
Remote: origin (https://github.com/joseluisq/gitnow.git)
Branch: master

From https://github.com/joseluisq/gitnow
 * branch            master     -> FETCH_HEAD
Created autostash: 473315a
HEAD is now at 9de2f93 update commands
Current branch master is up to date.
Applied autostash.

push

Push commit changes to remote repository.

Note: This command is equivalent to git push --set-upstream [your arguments...].

# Auto mode (current origin and branch)
push
# Manual mode
push <origin_name> <branch_name> <--some_other_flags>

upstream

Commit all changes and push them to remote server.

Note: This command does commit-all and then push. No flags supported.

upstream

move

Switch from current branch to another but stashing uncommitted changes

Note: This command does git stash then git checkout <other_branch> and finally git stash pop (possible to disable). It also takes care that <other_branch> matches with the existing local branches.

Additional options:

  • Use -u (or --upstream) flag to fetch a remote branch.
  • Use -n (or --no-apply-stash) flag to prevent stashed changes to be applied.
move other_branch

# Branch `ghost_branch` was not found. No possible to switch.
move ghost_branch

# With -u flag the branch will be fetched from remote origin.
move -u feature/new_remote_branch

# With -n flag stashed changes will not be applied.
move -n feature/new_remote_branch

# Possible to combine two option flags
move -un feature/another_remote_branch

merge

Merge a local branch into the active one

Note: This command does a simple git merge <other branch>.

Additional options:

  • Use -a (or --abort) flag instead of a branch name to abort a conflicted merge.
  • Use -c (or --continue) flag instead of a branch name to continue a merge.
merge other_branch

# Local branch ghost_branch was not found. Not possible to merge.
merge ghost_branch

# With -a flag the conflicted merge will be aborted.
merge -a

assume

Ignore changes in certain files temporarily.

Note: This command performs git update-index --[no-]assume-unchanged to ignore changes in certain files temporarily or revert those changes back.

Options:

  • -n --no-assume: No assume unchanged files to be ignored (revert option)
  • -h --help: Show information about the options for this command
# a) Ignore files temporarily
assume Cargo.toml README.md

# b) Revert file ignored changes
assume -n Cargo.toml README.md

feature

Creates a new feature (Gitflow) branch from current branch.

Note: Your new branch will always be lowercase without special characters or whitespaces (underscores instead).

feature feat1
# > feature/feat1
feature "This is my New FEATURE Branch"
# > feature/this_is_my_new_feature_branch

hotfix

Creates a new hotfix (Gitflow) branch from current branch.

Note: Your new branch will always be lowercase without special characters or whitespaces (underscores instead).

hotfix fix1
# > hotfix/fix1
hotfix "This is my New FIX Branch"
# > hotfix/this_is_my_new_fix_branch

bugfix

Creates a new bugfix (Gitflow) branch from current branch.

Note: Your new branch will always be lowercase without special characters or whitespaces (underscores instead).

bugfix fix1
# > bugfix/fix1
bugfix "This is my New bugFIX Branch"
# > bugfix/this_is_my_new_bugfix_branch

release

Creates a new release (Gitflow) branch from current branch.

Note: Your new branch will always be lowercase without special characters or whitespaces (underscores instead).

release fix1
# > release/fix1
release "This is my New release Branch"
# > release/this_is_my_new_bugfix_branch

logs

Shows logs in a fancy way.

Note: This command does git log HEAD by default using a pretty format. Add your git log flags as usual to overwrite it.

# shows all logs (default)
logs

# shows logs using git log parameters and flags (custom)
logs 8b09088
logs --before "yesterday" --after="1 week ago"

github

Clone a GitHub repository using SSH.

Examples:

github username/repo-name
github username repo-name

# requires a `user.github` username Git config entry
github repo-name

bitbucket

Clone a Bitbucket Cloud repository using SSH.

Examples:

bitbucket username/repo-name
bitbucket username repo-name

# requires a `user.bitbucket` username Git config entry
bitbucket repo-name

Note: For cloning some repo only, it's necessary to set your Github or Bitbucket username to global config before like:

# a) GitHub
git config --global user.github "your_username"
# b) Bitbucket
git config --global user.bitbucket "your_username"

Bonus

Contributions

Pull requests and issues are welcome.

License

MIT license

Β© 2016-present Jose Quintana

More Repositories

1

gimage

A PHP library for easy image handling. πŸ–Ό
PHP
151
star
2

alpine-php-fpm

Lightweight & optimized Multi-Arch Docker Images (x86_64/arm/arm64) for PHP-FPM (PHP 8.0, 8.1, 8.2) with essential extensions on top of latest Alpine Linux. 🐘
Dockerfile
129
star
3

rust-linux-darwin-builder

Use the same Docker image to cross-compile Rust x86_64/ARM64 programs for Linux and macOS (osxcross).
Dockerfile
94
star
4

printd

Print HTML elements or pages in modern browsers.
TypeScript
73
star
5

prelodr

A simple Material preloader inspired by Google Inbox.
JavaScript
68
star
6

awesome-bash-commands

A curated list of awesome Bash useful commands. Inspired by awesome-shell and bash-handbook.
Shell
52
star
7

macosx-sdks

Some Mac OS X SDKs for development purposes with osxcross.
51
star
8

paket

A simple and fast package manager for the Fish shell written in Rust. 🐠
Rust
50
star
9

hyperapp-starter

Minimal Hyperapp, Typescript and Parcel starter. πŸ“¦πŸš€πŸŽ‰
TypeScript
43
star
10

slendr

A responsive & lightweight (2KB gzipped) slider for modern browsers. [UNMAINTAINED]
TypeScript
38
star
11

ubigeos-peru

Datos JSON y SQL sobre departamentos, provincias y distritos del PerΓΊ.
PHP
34
star
12

sortboard

A small ES6 library for easy sorting and filtering of elements.
TypeScript
29
star
13

fastify-cluster-example

A simple example of how to running a Fastify server in multi-threaded mode.
TypeScript
22
star
14

timelite

String date and time utilities πŸ•™
TypeScript
17
star
15

vue-vform

Vue.js 2 form component that integrates jQuery Validation and Axios.
Vue
15
star
16

pokemons

Full JSON file with every PokΓ©mon basic info. Useful for prototyping.
13
star
17

go-tspath

A fast and persistent Typescript paths replacer written in Go.
Go
13
star
18

vue-input-number

A custom input number component for Vue.js 2
Vue
13
star
19

preact-starter

Minimal Preact, Typescript and Parcel starter. πŸš€
TypeScript
12
star
20

jquery.xfilterlist

[Deprecated] A simple jQuery grid list plugin for easy filter and sorting.
HTML
10
star
21

alpine-cgit

Multi-Arch Docker images for the hyperfast web frontend for Git repositories on top of Alpine and Nginx.
Dockerfile
10
star
22

awesome-mysql-queries-commands

🐬 A curated list of awesome MySQL useful queries and commands.
10
star
23

printd-vue-component-example

Example of printing a Vue 2 component using Printd.
JavaScript
9
star
24

codeigniter3-hmvc-boilerplate

Boilerplate for creating CodeIgniter 3 HMVC with Propel 2 ORM and OAuth2
PHP
8
star
25

enve

Cross-platform tool to run a program in a modified environment providing a .env file.
Go
7
star
26

git-cheat-sheet

Another Git cheat sheet yet :octocat:
6
star
27

docker-mysql-client

MySQL 8 client programs with easy database export and import functionality.
Dockerfile
6
star
28

koa-graphql-rethinkdb

GraphQL API Server example using Koa, Apollo GraphQL Server & RethinkDB. πŸš€
TypeScript
6
star
29

git-useful-aliases

Small list of useful Git aliases.
Shell
6
star
30

karma-jasmine-typescript

Sample of Unit Testing using Karma, Jasmine and Typescript.
JavaScript
5
star
31

utetris

Custom Mootools web version of famouse Tetris game.
JavaScript
5
star
32

jquery.xrequest

[Deprecated] Simple plugin to Ajax Request
CSS
5
star
33

helipad

A cross-platform, lightweight and fast CI/CD Server/Client written in Rust (WIP).
Rust
5
star
34

vue-typescript-starter

Tiny Vue 2 & Typescript frontend starter. πŸš€
JavaScript
5
star
35

alpine-mysql-client

Docker MySQL (MariaDB) client with easy export and import tools.
Shell
5
star
36

react-prelodr

A React component based on Prelodr.
JavaScript
4
star
37

svexport

Small PHP character-separated values exporter (CSV and TSV).
PHP
4
star
38

micro-one-dark

One Dark colorcheme for Micro.
Lua
4
star
39

peru-geojson-datasets

Estructuras de datos geogrΓ‘ficos GeoJSON representando departamentos, provincias y distritos del PerΓΊ.
4
star
40

sprintfit

A fast 450b sprintf & vsprintf format specifier focused on strings with no dependencies. ⚑️
TypeScript
4
star
41

ruta

A lightweight HTTP routing library for PHP 8+ without external dependencies. (WIP)
PHP
4
star
42

uFilterGrid

[Deprecated] A simple Mootools grid list plugin for easy filter and sorting.
HTML
4
star
43

laravel-ci-deployment

Laravel 5.4 + Circle CI + Deployer example
PHP
4
star
44

nano-crypto

Nano ID + Crypto utility functions with full Typescript support.
TypeScript
3
star
45

php-bitbucket-deployment

Simple PHP script to automatic Bitbucket deployment.
PHP
3
star
46

json-datasets

Example of various datasets in JSON format for different purposes.
3
star
47

cline

A fast and lightweight CLI package for Go without external dependencies.
Go
3
star
48

alpine-curl

An unofficial multi-arch cURL Docker image using latest Alpine Linux with Zstandard support.
Dockerfile
3
star
49

leap

A lightweight micro HTTP framework for PHP 8.1+ (experimental)
PHP
2
star
50

nginx-freebsd-server-configs

Small configs for run Nginx 1.10.1 on FreeBSD 10.2 + SSL
Nginx
2
star
51

gutr-css

Hackable gutters for your box model.
CSS
2
star
52

es6-browserify-gulp-boilerplate

A simple ES6 Babel, Browserify and Gulp boilerplate.
JavaScript
2
star
53

semver-aliases

A simple Go package to create deduplicated version aliases based on valid SemVer release names.
Go
2
star
54

lumen-restful-boilerplate

A simple boilerplate to start your first RESTfull API with PHP Lumen
PHP
2
star
55

lumen-54-boilerplate

Lumen 5.4 boilerplate for starting your first API.
PHP
2
star
56

grunt-deployit

Deploy your files easily using FTP.
JavaScript
2
star
57

fedora-sublime-text-3-sh-installer

Sublime Text 3 Shell Installer for Fedora Linux x64
Shell
2
star
58

kde-app-launcher-archlinux-icons

ArchLinux icon variants for KDE Plasma 5 application launcher.
2
star
59

video-source-url

Get video source from Youtube or Vimeo URL.
JavaScript
2
star
60

iterm2-material-theme

Material color theme for iTerm2 inspired in Sublime Material Theme.
2
star
61

slim3-todos-example

ToDo API example using PHP Slim 3, Laravel Eloquent and SQLite 3.
PHP
2
star
62

technically-oriented-pdf-collection

Technically-oriented PDF Collection (Papers, Specs, Decks, Manuals, etc)
HTML
2
star
63

tslint-config-standard-plus

A TSLint config for JavaScript Standard Style with a plus of useful rules.
TypeScript
2
star
64

peru-elecciones-generales-2021-scraper

JSON Scraper de las Elecciones Generales PerΓΊ 2021.
Dart
2
star
65

fastify-dockerized-sample

Very bare sample of a dockerized Fastify server
JavaScript
1
star
66

gitd

Use Git to fetch all source files from any repository. :octocat:
JavaScript
1
star
67

deno-examples

Some Deno examples for NodeJS Meetup Leipzig #3
TypeScript
1
star
68

goipcc

A simple Unix IPC Socket client for Go. For more flexibility try joseluisq/gonetc instead.
Go
1
star
69

seqr

A small ES6 package for execute functions sequentially.
JavaScript
1
star
70

echo-dockerclient

Tiny Echo middleware for Go Docker Client.
Go
1
star
71

atom-essentials

Some essential packages for more friendly development in Atom.
Shell
1
star
72

php-oauth2-demo

Example using OAuth2
PHP
1
star
73

docker-alpine-nginx-php7

Docker Nginx & PHP 7 image on the top of Alpine Linux. 🐳 [UNMAINTENATED] Use instead https://github.com/joseluisq/alpine-php-fpm
Nginx
1
star
74

usize

Useful Mootools class for resize DOM objects
JavaScript
1
star
75

uslider

Simple Mootools CSS3 Adaptable Slider
JavaScript
1
star
76

sleep-non-blocking-function

Deno & Node examples implementing a non-blocking sleep function.
TypeScript
1
star
77

emitus

Small Typescript Event Emitter. ⚑
TypeScript
1
star
78

node-sass-app-compiler

AplicaciΓ³n Nodejs para compilar Sass usando Libsass y GruntJS.
JavaScript
1
star
79

composer-essentials

Some PHP Composer global packages.
Shell
1
star
80

umessagebox

Simple Mootools modal messagebox
JavaScript
1
star
81

rpasswd

A small and secure password generator and encryptor tool.
Go
1
star
82

ng-util-directives

Some Angular 1.x useful directives
JavaScript
1
star
83

react-app-boilerplate

Create React App bootstrap but customized + config files.
JavaScript
1
star
84

codeigniter-composer-boilerplate

A boilerplate for getting started with latest CodeIgniter using Composer.
1
star
85

golang-code-examples

Some code examples of my GoLang learning πŸŽ“
Go
1
star
86

ffds

Small script for build a fast Front-End directory structure.
Shell
1
star
87

myftp

A PHP small class for FTP handling.
PHP
1
star
88

angular-apollo-client-starter

Example using Angular 4 & Apollo Client
TypeScript
1
star
89

hacker-news-stream

The Hacker News top stories but in Streams.
JavaScript
1
star
90

php-ga-tracking-redirect

Simple PHP Google Analytic Tracking with custom 301 redirection.
PHP
1
star
91

node-random-strings-demo

Random strings demo using Budo + Browserify
HTML
1
star
92

angular-fbxnd

Angular 1.x bindings for JavaScript Facebook SDK
1
star
93

awesome-medium-programming

A curated list of interesting Medium Programming Articles.
1
star
94

rust-tspath

A Typescript paths replacer written in Rust. ⚑ Supersed by https://github.com/joseluisq/go-tspath
Rust
1
star
95

minimal-boilerplate

Minimal Front-End boilerplate with npm run tasks built-in.
HTML
1
star
96

react-boilerplate

Another React boilerplate.
JavaScript
1
star
97

fedora-atom-sh-installer

Atom shell installer for Fedora Linux x86_x64
Shell
1
star
98

mydb

A small PHP Data Objects extension class for database handling.
PHP
1
star