swiftly icon indicating copy to clipboard operation
swiftly copied to clipboard

Update to `~/.zprofile` etc. should be commented with ~"Added by swiftly on 2024-07-15"

Open BrianHenryIE opened this issue 1 year ago • 2 comments

As I was working on #134, it was adding an invalid entry to .zprofile – the final line in this codeblock. I saw as other tools had modified the file they had sometimes commented who the line was added by

% cat /Users/brianhenry/.zprofile

export THEOS=~/theos
export THEOS_DEVICE_IP=172.20.10.13


# Added by Toolbox App
export PATH="$PATH:/Users/brianhenry/Library/Application Support/JetBrains/Toolbox/scripts"
# Created by `pipx` on 2023-06-20 22:05:23
export PATH="$PATH:/Users/brianhenry/.local/bin"
. $HOME/Library/Application/env.sh

It would be nice if swiftly were to do the same, I think add before 669 here:

https://github.com/swiftlang/swiftly/blob/bcfd8439a078893c11d3331c193e2b6a7b431887/install/swiftly-install.sh#L667-L670

     echo "# Added by swiftly on $(date '+%Y-%m-%d'). https://github.com/swiftlang/swiftly/"
# Added by swiftly on 2024-07-15. https://github.com/swiftlang/swiftly/
. "$HOME/Library/Application Support/swiftly/env.sh"

BrianHenryIE avatar Jul 16 '24 03:07 BrianHenryIE

@cmcgee1024 we should keep this in mind when we rewrite the installer

adam-fowler avatar Jul 23 '24 10:07 adam-fowler

The new installer writes # Added by swiftly. I'm not sure if the date stamp adds much value. How does everyone feel about this?

cmcgee1024 avatar Sep 12 '24 19:09 cmcgee1024