Commit 62eb6ab
authored
Support linux install path from src (#1409)
This PR fix #1304.
I found that the add func add_to_PATH [1] doesn't persist the path
to the $PATH env variable.
To persist in the current shell is necessary to use a dot or `source`
see doc [2].
_When a script is run using source it runs within the existing shell,
any variables created or modified by the script will remain available
after the script completes. In contrast if the script is run just as
filename, then a separate subshell (with a completely separate set of
variables) would be spawned to run the script._
To persist the PATH among the reboot/new shell, it is necessary to
update the _.profile_ with `echo 'PATH="$PATH:$installPath'
>>~/.profile`.
I don't know if this is the correct behavior, Prior to this commit, it
was working because the `/usr/local/bin` is already in the PATH.
[1]: https://github.com/git-ecosystem/git-credential-manager/blob/afcb6b87302b34d1809a0a057f24c7ba7a3ff5db/src/linux/Packaging.Linux/install-from-source.sh#L94
[2]: https://ss64.com/bash/source.htmlvvvvvvvFile tree
3 files changed
+33
-11
lines changed- src/linux/Packaging.Linux
3 files changed
+33
-11
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
| 12 | + | |
12 | 13 | | |
13 | 14 | | |
14 | 15 | | |
| |||
23 | 24 | | |
24 | 25 | | |
25 | 26 | | |
26 | | - | |
27 | | - | |
| 27 | + | |
| 28 | + | |
28 | 29 | | |
29 | 30 | | |
30 | 31 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
33 | 37 | | |
34 | 38 | | |
35 | 39 | | |
36 | 40 | | |
37 | 41 | | |
38 | 42 | | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
39 | 48 | | |
40 | 49 | | |
41 | 50 | | |
| |||
50 | 59 | | |
51 | 60 | | |
52 | 61 | | |
53 | | - | |
54 | | - | |
55 | | - | |
56 | | - | |
| 62 | + | |
57 | 63 | | |
58 | 64 | | |
59 | | - | |
60 | | - | |
| 65 | + | |
| 66 | + | |
61 | 67 | | |
62 | 68 | | |
63 | 69 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
16 | 20 | | |
17 | 21 | | |
18 | 22 | | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
19 | 34 | | |
20 | 35 | | |
21 | 36 | | |
22 | 37 | | |
23 | 38 | | |
24 | | - | |
| 39 | + | |
25 | 40 | | |
26 | 41 | | |
27 | 42 | | |
| |||
225 | 240 | | |
226 | 241 | | |
227 | 242 | | |
228 | | - | |
229 | | - | |
| 243 | + | |
| 244 | + | |
0 commit comments