Skip to content

Commit

Permalink
Merge pull request #27 from arcticicestudio/feature/gh-23-conditional…
Browse files Browse the repository at this point in the history
…-includes

Conditional includes
  • Loading branch information
arcticicestudio authored Aug 2, 2017
2 parents 7c1dc3c + f304e0c commit 427e6cb
Show file tree
Hide file tree
Showing 4 changed files with 38 additions and 15 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ snowblocks/bash/.log


# +--- git ---+
snowblocks/git/gitconfig_auth
snowblocks/git/gitconfig_auth_job
45 changes: 31 additions & 14 deletions snowblocks/git/gitconfig
Original file line number Diff line number Diff line change
@@ -1,25 +1,42 @@
# ++++++++++++++++++++++++++++++++++++++++++++++++++++++
# title Git Configuration +
# project igloo +
# repository https://github.com/arcticicestudio/igloo +
# author Arctic Ice Studio +
# email [email protected] +
# copyright Copyright (C) 2017 +
# ++++++++++++++++++++++++++++++++++++++++++++++++++++++
# +++++++++++++++++++++++++++++++++++++++++++++++++++++
# title Git Configuration +
# project igloo +
# repository https://github.com/arcticicestudio/igloo +
# author Arctic Ice Studio +
# email [email protected] +
# copyright Copyright (C) 2017 +
# +++++++++++++++++++++++++++++++++++++++++++++++++++++
#
# [References]
# Git
# (https://git-scm.com/docs/git-config)
# (https://git-scm.com/book/tr/v2/Customizing-Git-Git-Configuration#Colors-in-Git)
# https://git-scm.com/docs/git-config
# https://git-scm.com/book/tr/v2/Customizing-Git-Git-Configuration#_colors_in_git
# https://git-scm.com/docs/git-config#_conditional_includes
# diff-so-fancy
# (https://github.com/so-fancy/diff-so-fancy#options)
[include]
# Includes sensible authentication data:
# https://github.com/so-fancy/diff-so-fancy#options

[includeIf "gitdir:~/yggdrasil/"]
path = ~/.gitconfig_auth

[includeIf "gitdir:~/code/bitbucket/"]
path = ~/.gitconfig_auth

[includeIf "gitdir:~/code/bitfroest/"]
path = ~/.gitconfig_auth

[includeIf "gitdir:~/code/github/"]
path = ~/.gitconfig_auth

[includeIf "gitdir:~/.igloo/"]
path = ~/.gitconfig_auth

# Includes sensible job authentication data:
# - user.name <USERNAME>
# - user.email <EMAIL>
# - user.signingkey <SIGNINGKEY>
# - user.useconfigonly true
path = ~/.gitconfig_auth
[includeIf "gitdir:~/code/job/"]
path = ~/.gitconfig_auth_job

[core]
repositoryFormatVersion = 0
Expand Down
5 changes: 5 additions & 0 deletions snowblocks/git/gitconfig_auth
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[user]
name = Arctic Ice Studio
email = [email protected]
signingkey =
useconfigonly = true
1 change: 1 addition & 0 deletions snowblocks/git/snowblock.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
"~/.git-commit-msg": null,
"~/.gitconfig": null,
"~/.gitconfig_auth": null,
"~/.gitconfig_auth_job": null,
"~/.gitignore": null
}
}
Expand Down

0 comments on commit 427e6cb

Please sign in to comment.