quickstart

Quick start

English · Architecture & deep dive

Get raku-pm running and install + load your first package in about 5 minutes.

1. Get raku-pm

Recommended: run from source (skip zef, no global writes):

git clone https://gitee.com/skyter10086/raku-pm.git
cd raku-pm
raku bin/raku-pm.raku --help      # prints help => environment is OK

Want a global command instead? zef install . (then raku-pm is on PATH). Below we use the source form; both entry points behave identically.

2. Set two environment variables

export RAKUPM_REPO=repo              # repo dir (indexes + local repos live here)
export RAKUPM_TARGET=$HOME/.raku-pm  # install target: store/ + site/ + lockfile

Both directories are created automatically on first run.

3. Install a real-world package

raku bin/raku-pm.raku install File::Temp

Sample output (real run; version numbers shift as the ecosystem updates):

将安装 2 个发行版(自底向上,依赖优先):
  · File::Directory::Tree:ver<0.2>:auth<zef:raku-community-modules>
  · File::Temp:ver<0.0.12>:auth<zef:raku-community-modules>
==> 下载源码包 [zef]:https://360.zef.pm/F/IL/FILE_DIRECTORY_TREE/8f155b8a....tar.gz
==> 存入存储:File::Directory::Tree 0.2 (24be1140)
  · 运行测试:File::Directory::Tree 0.2
    ✓ 01-basic.rakutest
==> 已激活 File::Directory::Tree 0.2
==> 下载源码包 [zef]:https://360.zef.pm/F/IL/FILE_TEMP/9e97bc86....tar.gz
==> 存入存储:File::Temp 0.0.12 (3ad733c0)
  · 运行测试:File::Temp 0.0.12
    ✓ 01-basic.rakutest
    ✓ 02-gc.rakutest
    ✓ 03-tempfile.rakutest
==> 已激活 File::Temp 0.0.12
✓ 完成。

Dependencies are installed bottom-up — the ones depended on go first, the target last. That ordering is the heart of a package manager.

4. Use it

export RAKULIB="inst#$HOME/.raku-pm/site"
raku -e 'use File::Temp; say "loaded File::Temp OK"'

If it prints loaded File::Temp OK, the package is installed and loadable. Pick an exact version with use File::Temp:ver<0.0.12>.

Next steps

  • More commands (search / installed / upgrade / uninstall / repos): see "Quick start" in ../README.md.

  • Architecture, atomic install, lockfile, generation rollback, mapping onto zef: see ./architecture.en.md.

RakuPM v1.0.3

一个教学用的 Raku 包管理器:多索引仓库、依赖解析、跨系统本地库(:from<native>)探测、内容寻址存储、锁文件、单版本激活、单后端 HTTP 客户端(curl)、索引 TTL 与网络重试

Authors

  • skyter10086

License

Apache-2.0

Dependencies

Test Dependencies

Provides

  • RakuPM::Author
  • RakuPM::Builder
  • RakuPM::CLI
  • RakuPM::Cleaner
  • RakuPM::CliCheck
  • RakuPM::CliSpec
  • RakuPM::Client
  • RakuPM::Client::Flusher
  • RakuPM::Client::Git
  • RakuPM::Client::Query
  • RakuPM::Client::SelfManager
  • RakuPM::Client::Tester
  • RakuPM::Distribution
  • RakuPM::FileLock
  • RakuPM::Fs
  • RakuPM::HTTP
  • RakuPM::HTTP::Backend
  • RakuPM::HTTP::Tinyish
  • RakuPM::Help
  • RakuPM::InstallOptions
  • RakuPM::Installer
  • RakuPM::Installer::Generations
  • RakuPM::Installer::ShellTemplates
  • RakuPM::Ledger
  • RakuPM::Lock
  • RakuPM::MD5
  • RakuPM::Message
  • RakuPM::NativeLib
  • RakuPM::Net
  • RakuPM::Platform
  • RakuPM::Prefix
  • RakuPM::Repositories
  • RakuPM::Repository
  • RakuPM::Repository::Ecosystem
  • RakuPM::Repository::Local
  • RakuPM::Repository::Matching
  • RakuPM::Resolver
  • RakuPM::Spec
  • RakuPM::Store
  • RakuPM::UI
  • RakuPM::Version

The Camelia image is copyright 2009 by Larry Wall. "Raku" is a trademark of the Yet Another Society. All rights reserved.

Built with Podlite — the markup and publishing tools behind this site.