Skip to content

Commit

Permalink
script to try setting up perl on toolforge kubernetes
Browse files Browse the repository at this point in the history
  • Loading branch information
Amorymeltzer committed Dec 6, 2023
1 parent d641885 commit 6c7cf05
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions crathighlighter/setup_perl.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
#!/usr/bin/env bash
# setup_perl by Amory Meltzer
# Set up my perl on a toolforge kube whatever


# Make CPAN always select the default option
export PERL_MM_USE_DEFAULT=1
# Use https with cpanm:
# http://blogs.perl.org/users/neilb/2021/11/addressing-cpan-vulnerabilities-related-to-checksums.html
export PERL_CPANM_OPT="--verify --from https://www.cpan.org"
# Generally the default but let's just make this explicit. Used throughout.
export PERL5_DIR="$HOME/perl5"

# Yay perlbrew. The default, but again, make explicit
export PERLBREW_ROOT="$PERL5_DIR/perlbrew"

# Install perlbrew
curl -L https://install.perlbrew.pl | bash

# Source perlbrew, build $PATH
. "$PERLBREW_ROOT/etc/bashrc"

# locallib install stuff
export PERL5LIB="$PERL5_DIR/lib/perl5${PERL5LIB:+:${PERL5LIB}}"
export PERL_LOCAL_LIB_ROOT="$PERL5_DIR${PERL_LOCAL_LIB_ROOT:+:${PERL_LOCAL_LIB_ROOT}}"
export PERL_MB_OPT="--install_base $PERL5_DIR"
export PERL_MM_OPT="INSTALL_BASE=/$PERL5_DIR"

perlbrew install-cpanm
perlbrew install --switch 5.36.0

# Install deps
cpanm --cpanfile ~/wiki/crathighlighter/cpanfile --installdeps .

0 comments on commit 6c7cf05

Please sign in to comment.