perlbrew, Seacan, pau, and other stuffs.
Kang-min Liu / @gugod
https://twitter.com/kaoru_nkchan/status/1499690097880748034/photo/1
$o->{a}[42]->foo()
safe.Perl environment manager.
perlbrew install perl-5.38.0
perlbrew use perl-5.38.0
perlbrew install perl-5.18.4
perlbrew use perl-5.18.4
Big Thanks to Travis CI for choosing perlbrew
can
perlbrew
do more ?
$tagline[0] = "perl environment manager.";
$tagline[1] = await thinking();
# perlbrew switch 5.36
# cpanm App::Ack App::Uni
# uni JOY | ack CAT
😹 - U+1F639 - CAT FACE WITH TEARS OF JOY
% perlbrew use 5.18
% uni WEARY | ack FACE
zsh: uni: command not found...
zsh: ack: command not found...
😩 🙀
Shipping
software
📦 📦 📦
xsawyerx> Riak distribution is awesome. You download a tarball, exract it, then run bin/riak
. Everything works from there.
xsawyerx> Can we do the same for perl apps ?
gugod> ok
https://metacpan.org/dist/App-Seacan
(proof of concept)-ish
Seeacan is a directory containing
Shipment of Seacan = rsync -ar
the entire directory
https://github.com/bookingcom/pakket
Basically a solution to a bigger problem.
meanwhile…
how do we distribute
pre-packaged software ?
perl
itselfdocker
, podman
)Install and run python applications
in isolated environments.
~/.local/pipx/venvs/$APP/
~/.local/bin/$APP
-> ~/.local/pipx/venvs/$APP/bin/$APP
Isolated installation for a single perl app.
$PATH
~/.local/pau/apps/$APP/
~/.local/pau/shims/$APP
a shell wrapper, in which PERL5LIB is tweakd~/.local/bin/$APP
-> ~/.locl/pau/shims/$APP
pau install uni -M App::Uni
pau install ack -M App::Ack
pau install cpanoc -M Pod::Cpandoc
* Installs App::ccdiff
pau instll ccdiff
pau install ack -M App::Ack
pau pp ack
perlbrew use 5.38
cpanm App::Uni App::Ack
perlbrew make-shim uni
perlbrew make-shim ack
cp ./uni ./ack ~/.local/bin
export PATH=~/.local/bin:$PATH
# uni cat grinning
😸 - U+1F638 - GRINNING CAT FACE WITH SMILING EYES
perl.AppDir
├── app
│ └── perl-5.38 # relocatableinc
│ ...
├── AppRun -> ./app/perl-5.38/bin/perl
├── perl.desktop
└── perl.png
appimagetool-x86_64.AppImage perl.AppDir
#=> perl-x86_64.AppImage
# ./perl-x86_64.AppImage -E 'say "Hello from $^V"'
Hello from v5.38.0
uni.AppDir
├── app
│ ├── perl-5.38
│ └── uni
├── AppRun
├── uni.desktop
└── uni.png
uni.Appdir/app/uni/
## uni.AppDir
# ./app/perl-5.38/bin/perl =cpanm -L ./app/uni --notest -q App::Uni
...
Successfully installed App-Uni-9.006
AppRun
#!/bin/sh
export PATH=$APPDIR/app/perl-5.38/bin:$APPDIR/app/uni/bin:$PATH
export PERL5LIB=$APPDIR/app/uni/lib/perl5
exec perl $APPDIR/app/uni/bin/uni "$@"
# ./uni-x86_64.AppImage cat grinning
😸 - U+1F638 - GRINNING CAT FACE WITH SMILING EYES
I
know
what we
can make
perlbrew do
…
New perlbrew commands
use
/switch
already workedThanks for
Listening
or
or
By clicking below, you agree to our terms of service.
New to HackMD? Sign up
Syntax | Example | Reference | |
---|---|---|---|
# Header | Header | 基本排版 | |
- Unordered List |
|
||
1. Ordered List |
|
||
- [ ] Todo List |
|
||
> Blockquote | Blockquote |
||
**Bold font** | Bold font | ||
*Italics font* | Italics font | ||
~~Strikethrough~~ | |||
19^th^ | 19th | ||
H~2~O | H2O | ||
++Inserted text++ | Inserted text | ||
==Marked text== | Marked text | ||
[link text](https:// "title") | Link | ||
 | Image | ||
`Code` | Code |
在筆記中貼入程式碼 | |
```javascript var i = 0; ``` |
|
||
:smile: | ![]() |
Emoji list | |
{%youtube youtube_id %} | Externals | ||
$L^aT_eX$ | LaTeX | ||
:::info This is a alert area. ::: |
This is a alert area. |
On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?
Please give us some advice and help us improve HackMD.
Do you want to remove this version name and description?
Syncing