Skip to content

Commit

Permalink
pythonpath option
Browse files Browse the repository at this point in the history
  • Loading branch information
Graham R Pugh committed Jul 31, 2020
1 parent bbc9352 commit 7b841dd
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 3 deletions.
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,12 @@

No date

- If there are any changes since the last tag, click [here][untagged] to see the changes.
## [0.15.4]

31.07.2020

- Added `--pythonpath` option so that you can select a different python with which to run `installinstallmacos.py`. Default is `$(which python)`.
- `installinstallmacos.py` now has a `--warnings` option about whether to show the Notes/Warnings in the list output or not. This has been hard-coded into `erase-install.sh` to maintain current behaviour.

## [0.15.3]

Expand Down Expand Up @@ -180,6 +185,7 @@ Thanks to '@ahousseini' for various contributions to this release
- Initial version. Expects a manual choice of installer from `installinstallmacos.py`.

[untagged]: https://github.com/grahampugh/erase-install/compare/v0.15.2...HEAD
[0.15.4]: https://github.com/grahampugh/erase-install/compare/v0.15.3...v0.15.4
[0.15.3]: https://github.com/grahampugh/erase-install/compare/v0.15.2...v0.15.3
[0.15.2]: https://github.com/grahampugh/erase-install/compare/v0.15.1...v0.15.2
[0.15.1]: https://github.com/grahampugh/erase-install/compare/v0.15.0...v0.15.1
Expand Down
12 changes: 10 additions & 2 deletions erase-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -322,7 +322,8 @@ check_newer_available() {
iim_downloaded=1

# run installinstallmacos.py with list and then interrogate the plist
python "$workdir/installinstallmacos.py" --list --workdir="$workdir" > /dev/null
[[ ! -f "$python_path" ]] && python_path=$(which python)
"$python_path" "$workdir/installinstallmacos.py" --list --workdir="$workdir" > /dev/null
i=0
newer_version_found="no"
while available_version=$( /usr/libexec/PlistBuddy -c "Print :result:$i:version" "$workdir/softwareupdate.plist" 2>/dev/null); do
Expand Down Expand Up @@ -413,7 +414,7 @@ run_installinstallmacos() {
installinstallmacos_args+="--auto"
fi

python "$workdir/installinstallmacos.py" $installinstallmacos_args
python "$workdir/installinstallmacos.py" --warnings $installinstallmacos_args

if [[ $list == "yes" ]]; then
exit 0
Expand Down Expand Up @@ -491,6 +492,10 @@ do
shift
installer_directory="$1"
;;
--pythonpath)
shift
python_path="$1"
;;
--extras)
shift
extras_directory="$1"
Expand Down Expand Up @@ -520,6 +525,9 @@ do
--path*)
installer_directory=$(echo $1 | sed -e 's|^[^=]*=||g')
;;
--pythonpath*)
python_path=$(echo $1 | sed -e 's|^[^=]*=||g')
;;
--extras*)
extras_directory=$(echo $1 | sed -e 's|^[^=]*=||g')
;;
Expand Down

0 comments on commit 7b841dd

Please sign in to comment.