@leverege/build-tools 2.52.0-pedro.2 → 2.52.0-pedro.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@leverege/build-tools",
3
- "version": "2.52.0-pedro.2",
3
+ "version": "2.52.0-pedro.3",
4
4
  "description": "A collection of build / support tools for Leverege developers",
5
5
  "main": "index.js",
6
6
  "repository": {
@@ -84,6 +84,26 @@ password: $ENCODED_KEY
84
84
  EOF
85
85
  echo "Updated $HOME/.pypirc"
86
86
 
87
- # Set UV_EXTRA_INDEX_URL env var
88
- export UV_EXTRA_INDEX_URL="https://_json_key_base64:$ENCODED_KEY@us-python.pkg.dev/leverege-registry/leverege-python-packages/simple"
89
- echo "Updated UV_EXTRA_INDEX_URL"
87
+
88
+ UV_EXTRA_INDEX_URL="https://_json_key_base64:$ENCODED_KEY@us-python.pkg.dev/leverege-registry/leverege-python-packages/simple"
89
+ UV_EXTRA_INDEX_URL_E=$(escape_for_sed "$UV_EXTRA_INDEX_URL")
90
+
91
+ # If fish shell is installed, update the fish shell configuration
92
+ if [[ $(command -v fish) != "" ]]; then
93
+ echo "Updating fish shell configuration"
94
+ fish -c "set -Ux UV_EXTRA_INDEX_URL $UV_EXTRA_INDEX_URL"
95
+ fi
96
+
97
+ # If bash shell is installed, update the bash shell configuration
98
+ if [[ $(command -v bash) != "" ]]; then
99
+ echo "Updating bash shell configuration"
100
+ # Use sed to remove any existing UV_EXTRA_INDEX_URL variable
101
+ sed -i '' "s|UV_EXTRA_INDEX_URL=.*|UV_EXTRA_INDEX_URL=$UV_EXTRA_INDEX_URL_E|" $HOME/.bashrc
102
+ fi
103
+
104
+ # If zsh shell is installed, update the zsh shell configuration
105
+ if [[ $(command -v zsh) != "" ]]; then
106
+ echo "Updating zsh shell configuration"
107
+ # Use sed to remove any existing UV_EXTRA_INDEX_URL variable
108
+ sed -i '' "s|UV_EXTRA_INDEX_URL=.*|UV_EXTRA_INDEX_URL=$UV_EXTRA_INDEX_URL_E|" $HOME/.zshrc
109
+ fi
@@ -27,6 +27,29 @@ password: $TOKEN
27
27
  EOF
28
28
  echo "Updated $HOME/.pypirc"
29
29
 
30
- # Set UV_EXTRA_INDEX_URL env var
31
- export UV_EXTRA_INDEX_URL="https://oauth2accesstoken:$TOKEN@us-python.pkg.dev/leverege-registry/leverege-python-packages/simple"
32
- echo "Updated UV_EXTRA_INDEX_URL"
30
+ escape_for_sed() {
31
+ printf '%s\n' "$1" | sed -e 's/[\/&]/\\&/g'
32
+ }
33
+
34
+ UV_EXTRA_INDEX_URL="https://oauth2accesstoken:$TOKEN@us-python.pkg.dev/leverege-registry/leverege-python-packages/simple"
35
+ UV_EXTRA_INDEX_URL_E=$(escape_for_sed "$UV_EXTRA_INDEX_URL")
36
+
37
+ # If fish shell is installed, update the fish shell configuration
38
+ if [[ $(command -v fish) != "" ]]; then
39
+ echo "Updating fish shell configuration"
40
+ fish -c "set -Ux UV_EXTRA_INDEX_URL $UV_EXTRA_INDEX_URL"
41
+ fi
42
+
43
+ # If bash shell is installed, update the bash shell configuration
44
+ if [[ $(command -v bash) != "" ]]; then
45
+ echo "Updating bash shell configuration"
46
+ # Use sed to remove any existing UV_EXTRA_INDEX_URL variable
47
+ sed -i '' "s|UV_EXTRA_INDEX_URL=.*|UV_EXTRA_INDEX_URL=$UV_EXTRA_INDEX_URL_E|" $HOME/.bashrc
48
+ fi
49
+
50
+ # If zsh shell is installed, update the zsh shell configuration
51
+ if [[ $(command -v zsh) != "" ]]; then
52
+ echo "Updating zsh shell configuration"
53
+ # Use sed to remove any existing UV_EXTRA_INDEX_URL variable
54
+ sed -i '' "s|UV_EXTRA_INDEX_URL=.*|UV_EXTRA_INDEX_URL=$UV_EXTRA_INDEX_URL_E|" $HOME/.zshrc
55
+ fi