Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/spk/ruby-apt-pkg
Ruby interface to Debian apt-pkg
https://github.com/spk/ruby-apt-pkg
apt binding debian ruby ruby-interface
Last synced: 14 days ago
JSON representation
Ruby interface to Debian apt-pkg
- Host: GitHub
- URL: https://github.com/spk/ruby-apt-pkg
- Owner: spk
- License: mit
- Created: 2014-01-07T16:26:50.000Z (almost 11 years ago)
- Default Branch: master
- Last Pushed: 2023-08-26T15:34:54.000Z (about 1 year ago)
- Last Synced: 2024-10-04T13:40:30.309Z (about 1 month ago)
- Topics: apt, binding, debian, ruby, ruby-interface
- Language: C++
- Homepage: http://www.rubydoc.info/gems/apt-pkg
- Size: 146 KB
- Stars: 17
- Watchers: 3
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: History.md
- License: LICENSE
Awesome Lists containing this project
README
# Ruby interface to apt-pkg
Goal of this project is to have a proper Ruby binding to APT like in
[Python](https://tracker.debian.org/pkg/python-apt).Currently install, remove packages commands are **not** implemented.
## INSTALL
```
apt install build-essential ruby-dev libapt-pkg-dev (>= 1.0)
gem install apt-pkg
```## USING
Basic usage:
``` ruby
require 'debian/apt_pkg'# Initialize the configuration and system of apt
Debian::AptPkg.init# Update the index files used by the cache
Debian::AptPkg::PkgCache.update# List packages stored in the cache
Debian::AptPkg::PkgCache.packages# List installed packages
Debian::AptPkg::PkgCache.packages.select { |pkg| pkg.is_installed }
```[Documentation](http://www.rubydoc.info/gems/apt-pkg)
## BUILD
``` console
rake compile
```## TEST
``` console
rake test
```## LICENSE
The MIT License
Copyright (c) 2014-2020 Laurent Arnoud
---
[![Build](https://img.shields.io/gitlab/pipeline/spkdev/ruby-apt-pkg/master)](https://gitlab.com/spkdev/ruby-apt-pkg/-/commits/master)
[![Version](https://img.shields.io/gem/v/apt-pkg.svg)](https://rubygems.org/gems/apt-pkg)
[![Documentation](https://img.shields.io/badge/doc-rubydoc-blue.svg)](http://www.rubydoc.info/gems/apt-pkg)
[![License](https://img.shields.io/badge/license-MIT-blue.svg)](http://opensource.org/licenses/MIT "MIT")
[![Project status](https://img.shields.io/badge/status-experimental-red)](https://github.com/spk/ruby-apt-pkg)