Browse Source

fixed a setup.sh error that would occur on macos

pull/199/head
Jonathan Dunn 8 months ago
parent
commit
654410530c
  1. 8
      installer/client/cli/utils.py
  2. 4
      setup.sh

8
installer/client/cli/utils.py

@ -388,14 +388,6 @@ class Alias:
for pattern in allPatterns:
self.remove(pattern)
def find_line(self, name):
for file in self.config_files:
with open(file, "r") as f:
lines = f.readlines()
for line in lines:
if line.strip("\n") == f"alias ${name}='{alias}'":
return line
def add_patterns(self):
allPatterns = os.listdir(self.patterns)
for pattern in allPatterns:

4
setup.sh

@ -40,8 +40,8 @@ for config_file in "${config_files[@]}"; do
echo -e "\n# Load custom aliases\n$source_line" >> "$config_file"
echo "Added source command for $bootstrap_file in $config_file."
fi
sed -i '/alias fabric=/d' "$config_file"
sed -i '/fabric --pattern/d' "$config_file"
sed -i '' '/alias fabric=/d' "$config_file"
sed -i '' '/fabric --pattern/d' "$config_file"
else

Loading…
Cancel
Save