---
name: "Arch::Library"
section: "3pm"
platform: "linux"
package: "libarch-perl"
version: "0.5.2-2"
release: "Debian 11 (Bullseye)"
platforms: ["linux"]
url: "https://new.carta.tech/Arch::Library"
---

# Arch::Library(3pm)

access arch revision libraries

## NAME

Arch::Library - access arch revision libraries

## SYNOPSIS

```
    use Arch::Library;
    my $library = Arch::Library->new;
    my $rev  = 'migo@homemail.com--Perl-GPL/arch-perl--devel--0--patch-1';
    my $log  = $library->get_revision_log($rev);
    my $cset = $library->get_revision_changeset($rev);
```

## DESCRIPTION

Arch::Library provides an interface to access pristine trees, changesets and logs stored in local revision libraries.

## METHODS

The following common methods (inherited and pure virtual that this class implements) are documented in Arch::Storage:

**new**, **init**, **working\_name**, **working\_names**, **fixup\_name\_alias**, **is\_archive\_managed**, **expanded\_revisions**.

**archives**, **categories**, **branches**, **versions**, **revisions**, **get\_revision\_descs**, **expanded\_archive\_info**, **get\_revision\_changeset**, **get\_changeset**, **get\_revision\_log**, **get\_log**.

Additionally, the following methods are available:

**fallback\_dir**, **working\_revision**, **add\_revision**, **find\_revision\_tree**, **find\_tree**.

- **fallback\_dir** \[*dir*\]

  Get or set the fallback directory. Defaults to `"undef"`.

  If no revision library exists, the fallback directory will be used as revision library when adding revisions with **add\_revision**.

- **working\_revision** \[*revision*\]

  Get or set the default revision for **find\_tree**, **get\_changeset** and **get\_log**.

- **find\_revision\_tree** *revision* \[*autoadd*\]

  - **find\_tree** \[*autoadd*\]

  Returns the path to the revision library structure for revision *revision* or **working\_revision**.

  Returns an empty string if *revision* is not in the revision library and *autoadd* is not set. If *autoadd* is set, *revision* will be added to the revision library.

## BUGS

No known bugs.

## AUTHORS

Mikhael Goikhman (migo@homemail.com--Perl-GPL/arch-perl--devel).

Enno Cramer (uebergeek@web.de--2003/arch-perl--devel).

## SEE ALSO

For more information, see tla, Arch::Storage, Arch::Library.
