Skip to content

Commit

Permalink
Merge pull request yegor256#374 from nai1ka/master
Browse files Browse the repository at this point in the history
Added info about packages which will be installed
  • Loading branch information
yegor256 authored Sep 27, 2024
2 parents 8209166 + 7cbdd00 commit ab23bb1
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/make.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- run: sudo make install
- run: sudo make install FORCE_INSTALL=true
- run: make env lint test
make-macos:
runs-on: macos-14
Expand All @@ -52,5 +52,5 @@ jobs:
run: brew install make bash
- name: 'Add make to PATH'
run: echo "/opt/homebrew/opt/make/libexec/gnubin" >> "$GITHUB_PATH"
- run: sudo make install
- run: sudo make install FORCE_INSTALL=true
- run: make env lint test
51 changes: 51 additions & 0 deletions steps/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,57 @@
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.


LINUX_ONLY_PACKAGES=(
"coreutils"
"xpdf"
"libxml2-utils"
)

MACOS_ONLY_PACKAGES=(
"gnu-sed"
"wget"
"poppler"
"libxml2"
)

PACKAGES_BOTH=(
"pmd"
"jpeek"
"texlive"
"coreutils"
"parallel"
"bc"
"cloc"
"jq"
"shellcheck"
"aspell"
"xmlstarlet"
"gawk"
"inkscape"
)

if [[ -z "$FORCE_INSTALL" ]]; then
echo "The following packages will be installed:"

if "${LOCAL}/help/is-linux.sh"; then
PACKAGES=("${LINUX_ONLY_PACKAGES[@]}" "${PACKAGES_BOTH[@]}")
else
PACKAGES=("${MACOS_ONLY_PACKAGES[@]}" "${PACKAGES_BOTH[@]}")
fi

for i in "${PACKAGES[@]}"; do
echo " - ${i}"
done

read -p "Do you want to proceed with the installation? (y/n): " -n 1 -r
echo
if [[ ! $REPLY =~ ^[Yy]$ ]]; then
echo "Installation aborted by user."
exit 1
fi
fi

set -e
set -o pipefail

Expand Down

0 comments on commit ab23bb1

Please sign in to comment.