Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conditional includes #27

Merged
merged 2 commits into from
Aug 2, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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