From 27570344d6d2eacbee273e498cccd65611b018b2 Mon Sep 17 00:00:00 2001 From: dogeystamp Date: Tue, 13 Aug 2024 21:43:47 -0400 Subject: [PATCH] bashrc: android fish location --- src/dot_config/bashrc | 5 ----- src/dot_config/bashrc.tmpl | 11 +++++++++++ 2 files changed, 11 insertions(+), 5 deletions(-) delete mode 100644 src/dot_config/bashrc create mode 100644 src/dot_config/bashrc.tmpl diff --git a/src/dot_config/bashrc b/src/dot_config/bashrc deleted file mode 100644 index 2de34d4..0000000 --- a/src/dot_config/bashrc +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/sh - -# Use fish in place of bash -# keep this line at the bottom of ~/.bashrc -[ -x /usr/bin/fish ] && SHELL=/usr/bin/fish exec fish diff --git a/src/dot_config/bashrc.tmpl b/src/dot_config/bashrc.tmpl new file mode 100644 index 0000000..22c6f02 --- /dev/null +++ b/src/dot_config/bashrc.tmpl @@ -0,0 +1,11 @@ +#!/bin/sh + +{{- $fish_path := "/usr/bin/fish" }} + +{{- if eq .chezmoi.os "android" }} +{{- $fish_path = "/data/data/com.termux/files/user/bin/fish" }} +{{- end }} + +# Use fish in place of bash +# keep this line at the bottom of ~/.bashrc +[ -x {{ $fish_path }} ] && SHELL={{ $fish_path }} exec fish