summaryrefslogtreecommitdiff
path: root/misc/dotfiles/bashrc.j2
diff options
context:
space:
mode:
authorDmitry Ilvokhin <d@ilvokhin.com>2024-02-24 18:36:32 +0000
committerDmitry Ilvokhin <d@ilvokhin.com>2024-02-24 18:36:32 +0000
commit2b29e812468ae2f33a4d37e2e280b7080f11ee86 (patch)
tree15826a929d63c05081399d970e8caaf6d0ecdc23 /misc/dotfiles/bashrc.j2
parent505d0e3202677729f9c5a9c03cb5ddfd9faf6d78 (diff)
downloadinfra-2b29e812468ae2f33a4d37e2e280b7080f11ee86.tar.gz
infra-2b29e812468ae2f33a4d37e2e280b7080f11ee86.tar.bz2
infra-2b29e812468ae2f33a4d37e2e280b7080f11ee86.zip
Add simple dotfiles management playbook
Diffstat (limited to 'misc/dotfiles/bashrc.j2')
-rw-r--r--misc/dotfiles/bashrc.j222
1 files changed, 22 insertions, 0 deletions
diff --git a/misc/dotfiles/bashrc.j2 b/misc/dotfiles/bashrc.j2
new file mode 100644
index 0000000..4a872fc
--- /dev/null
+++ b/misc/dotfiles/bashrc.j2
@@ -0,0 +1,22 @@
+# Source system-wide settings of there are any.
+if [ -f /etc/bashrc ]; then
+ . /etc/bashrc
+fi
+
+{% if ansible_facts['os_family'] == "Darwin" %}
+# Specific settings for macOS.
+if [[ "$OSTYPE" == "darwin"* ]]; then
+
+# Silence bash deprecation warning.
+export BASH_SILENCE_DEPRECATION_WARNING=1
+
+# Enable colors for `ls` output.
+export CLICOLOR=1
+
+# Get GitHub token from keychain to avoid homebrew rate limiting on GitHub
+# side.
+export HOMEBREW_GITHUB_API_TOKEN=`security \
+ find-generic-password -s "Homebrew GitHub Token" -w`
+
+fi
+{% endif %}