A simple wrapper for 'pacman' with a syntax similar to 'apt' to help people transitioning to Arch and Arch based distributions like Manjaro.

aptpac

latest release badge license badge Build-x64 status badge Build-arm64 status badge Build-armhf status badge repository size badge

aptpac is a program which helps with the transition to Arch Linux and Arch based distros like Manjaro.

It simplifies using pacman as it works like the easier to use APT package manager found in Debian based distributions.

The program comes in 2 variants, a bash shell version, and a C code variant. It is recommended to use the C code variant since C code is quicker and better than shell scripts. the C variant is more friendly and more feature rich, but the bash version gets new commands before as its simpler and easier to debug.

Note

This program has nothing to do with the other projects named aptpac like this one. please don't ask for support for other aptpac's in this repository or ask for support for this aptpac in the other aptpac's repositories.

Usage

USAGE:
        aptpac [option] [options for the option]
        EXAMPLE: aptpac search qemu
AVAILABLE OPTIONS:
        install - install a package.
        install-local - install a local package. accpets the path to the package as a argument.
        remove - uninstall a package.
        purge - uninstall a package along with its configuration files.
        search - search a package.
        find - (pacman -F) in debian: 'apt-file search'.
        update - equivalent of 'apt update' in debian.
        upgrade - equivalent of 'apt upgrade' in debian.
        full-upgrade - full system upgrade.
        full-upgrade - same as 'upgrade'.
        autoclean - clean up all local caches.
        clean - same as 'autoclean'.
        autoremove - remove packages that are no longer needed.
        show - show the information of a package that is installed.
        show-all - same as 'show', but shows packages from the repos.
        list-installed - list all installed packages.
        help - show this help.
        version - show version and about information.

options are not case sensitive (C edition only).

Bash version only (for now, scroll down for learning mode in the C edition):

--learning-mode=<on|off> - accepts 'on' or 'off' as values. turns learning mode on or off.

Installation

Since there are 2 variants of aptpac, there are 2 install methods, please choose the variant you would like:

  1. C (recommended)
  2. Bash

Guide to installing C aptpac:

sudo pacman -S cmake make git gcc
cd $HOME
git clone https://github.com/Itai-Nelken/aptpac
cd ./aptpac/C-edition
mkdir build
cd build 
cmake -DCMAKE_BUILD_TYPE=Release -DCALLCOMMAND="aptpac" ..
make
# Optional however crucial
sudo make install # This moves aptpac to /usr/local/bin so it can be run easily

Learning mode (for C-edition only, for bash edition, go here)

If you want to enable 'learning mode' which prints the commands being run, add -DLEARN=1 before the .. in the cmake line during installation so it looks like this:

cmake -DLEARN=1 -DCALLCOMMAND="aptpac" -DCMAKE_BUILD_TYPE=Release ..

Guide to installing Bash aptpac:

sudo pacman -S wget
cd $HOME
mkdir ~/.aptpac
wget https://github.com/Itai-Nelken/aptpac/releases/download/2.5/aptpac.sh -O ~/.aptpac/aptpac.sh
chmod +x .aptpac/aptpac.sh
echo "alias aptpac=\"~/.aptpac/aptpac.sh\"" >> $HOME/.bashrc
source ~/.bashrc

Uninstalling

Choose the correct uninstall method - the one you chose when installing

Guide to uninstalling C aptpac:

cd ~/aptpac/C-edition/build
sudo make uninstall
cd $HOME
sudo rm -r ./aptpac

Guide to uninstalling Bash aptpac:

cd $HOME
sed -i '/alias aptpac=.*aptpac.*/d' .bashrc
rm -r .aptpac
source .bashrc

Reviews

CleanMachine1 - aptpac is a great piece of software, making the move to arch easier (the better Linux in my opinion).

Daily builds

Daily builds for x64, arm64, and armhf are now available, these can be found in the actions tab on the aptpac repo, once you have clicked on the actions tab, click on 'Build-x64', 'Build-arm64', or 'Build-armhf' then click on the latest build with a green ✔️ , scroll down to the 'artifacts' section, and click on the zip there. keep in mind you need a github account to download them.

Build checks

Build checks for arm64, armhf, and X86-64 are run for every commit and pr. you can see the status in the badges at the top of the README. The check are not run for README updates.

Comments
  • Some more to add

    Some more to add

    I have recently switched to running Arch and have some suggestions.

    I have been clearing dependencies which are unneeded and the command for that is

    sudo pacman -R $(pacman Q-dtq)

    and just for orphan dependencies you just run the same but run what is it inside of the brackets.

    I know this feature isn't a thing with apt but it is still a useful command

    PS: do you actually use Arch

  • Fix the error on initial run on new installation

    Fix the error on initial run on new installation

    On a new installation, the programme will attempt to read the config file which yet does not exisit, causing the error config_load: fopen: No such file or directory.

  • PKGBUILD?

    PKGBUILD?

    A PKGBUILD would allow it to be put into the AUR giving it a potential bigger audience.

    I would be willing to create one.

    Or it maybe useful to make your own, so you can learn if you haven't, DollarSkip's PKGBUILD seems to fit exactly

  • Handle empty autoremove properly

    Handle empty autoremove properly

    When there is not unneeded dependencies to remove, we will encounter:

    $ aptpac autoremove
    error: argument '-' specified with empty stdin
    

    It looks weird and abrupt.

    I modified it so that it can detect if there is a need to run pacman -R:

    Test

    If there is something to remove, it works as it did in the past:

    $ aptpac autoremove                            
    checking dependencies...
    
    Packages (2) qoauth-2.0.0-3  qt5-xmlpatterns-5.15.6+kde+r0-1
    
    Total Removed Size:  6.77 MiB
    
    :: Do you want to remove these packages? [Y/n] 
    

    After the command above, run it again:

    $ aptpac autoremove
    Nothing to be autoremoved.
    

    There will be a friendly prompt.

  • WIP: Learning mode

    WIP: Learning mode

    continuation of #2

    Progress so far (will be updated)

    bash edition

    • you can toggle learning mode on and off in runtime, simply run aptpac --learning-mode=on to turn it on and aptpac --learning-mode=off to turn it off.

    C-edition

    There are 2 ways to enable/disable learning mode in the C edition:

    1. using the --config flag. the setting is saved in ~/.aptpac/aptpac.config
    • to enable learning mode: aptpac --config set learn.
    • to disable learning mode: aptpac --config unset learn
    1. You can use the environment variable APTPAC_LEARN to turn it on and off in runtime without having to recompile.
    • run aptpac like this: APTPAC_LEARN=1 aptpac <command>
    • add this: export APTPAC_LEARN=1 to your bashrc or equivalent and source it or restart your terminal to have learning mode on until you remove that line or change the value of the variable.

    ~~- you need to recompile to toggle it. to turn it on, add -DLEARN=1 to the cmake line. to turn it off (only needed if you are recompiling the same build without re-generating the build files from scratch), add -DLEARN=0.~~

  • Add bash completions

    Add bash completions

    Add bash completions for aptpac so that commands an be auto completed using . I am not sure but the bash completions file of apt may hel a lot here. Also I may try doing this if I get a chance.

Optimized Linux kernel for Arch / Arch-based distros

Linux kernel ============ There are several guides for kernel developers and users. These guides can be rendered in a number of formats, like HTML an

Oct 5, 2022
This is new projec based in apps to chat or messages people to people

Stranger This is new projec based in apps to chat or messages people to people Esta aplicacion tendra las siguientes caracteristicas: 1* Es 100% segur

Nov 3, 2021
JeVois-Pro People Counter : Implement people counter on JeVois-Pro Deep Learning Smart Camera
JeVois-Pro People Counter : Implement  people counter  on JeVois-Pro Deep Learning Smart Camera

JeVois-Pro People Counter Refer to the OpenCV People Counter article to implement a people counter on the JeVois-Pro Deep Learning Smart Camera. First

Nov 10, 2021
Windows 2000 styled installer for Panther based distributions of Microsoft Windows (WIM files).

An advanced installer for Microsoft Windows that mimics the looks of the Windows XP and older installers. Takes any modern (Vista and newer) Windows ISO or WIM file and creates a old styled Windows Setup experience on the go.

Dec 17, 2022
Simple Pacman clone written in Zig.

pacman.zig Like https://github.com/floooh/pacman.c, but in Zig Zig bindings for the sokol headers are here: https://github.com/floooh/sokol-zig Build

Dec 30, 2022
Dec 25, 2022
🐧MAJOR BUG GRANTS ROOT FOR ALL MAJOR LINUX DISTRIBUTIONS

?? MAJOR BUG GRANTS ROOT FOR ALL MAJOR LINUX DISTRIBUTIONS CTF quality exploit bla bla irresponsible disclosure terminal: [email protected]:~$ wget https://g

Jun 22, 2022
Arobase is a simple programming language with a c-like syntax.
Arobase is a simple programming language with a c-like syntax.

Arobase Arobase is a simple programming language with a c-like syntax. Requirements gcc gas (gnu as) ld A 64 bits linux distribution (generated assemb

Nov 28, 2022
A Simple Language (PHP-Like Syntax)

SL A Simple Language (PHP-Like Syntax) Usage: SL.exe <filename> A 64-bit windows executable is provided (SL.exe) alongside some demo SL code (main.sl)

Nov 15, 2021
3D Pacman with C++ and OpenGL
3D Pacman with C++ and OpenGL

Pacman 3D 3D version of my Homemade Pacman, made with C++ and OpenGL Dependencies ASSIMP (to load the 3D models) and SFML (to play sounds) are needed

Sep 1, 2022
PACMAN for Raspberry Pi Pico (QVGA LCD)
PACMAN for Raspberry Pi Pico (QVGA LCD)

PACMAN for Raspberry Pi Pico ラズベリーPi PicoにQVGAの液晶を接続して動作する本格的なパックマンです。 小型スピーカーを接続して音声も鳴らせます。 とてもシンプルな回路なので、簡単に製作することができます。 液晶は240x320ドット、コントローラにILI934

Dec 28, 2022
learning how to use arch and linux in general
learning how to use arch and linux in general

dotfilesPEROEPICO what I use distro: arch wm: dwm launchers: sxhkd & dmenu, j4-dmenu-desktop browser: firefox (sponsorskip, privacy badger, ublock ori

Nov 12, 2021
(Simple String Format) is an syntax of format and a library for parse this.

SSFMT (Simple String Format) is an syntax of format and a library for parse this. SSFMT != {fmt} SSFMT is NOT an API/library for parse {fmt} syntax !

Jan 30, 2022
This is a simple version of Apex-Legends-SDK since so many people having struggles with python binding
This is a simple version of Apex-Legends-SDK since so many people having struggles with python binding

This is a simple version of Apex-Legends-SDK since so many people having struggles with python binding

Nov 30, 2022
Fluid Visualization - The code compilation is only tested on Arch Linux x86_64

Fluid Visualization The code compilation is only tested on Arch Linux x86_64, Linux kernel 5.15.13-arch1, with gcc 11.1.0, CMake 3.22.1, Xorg X server

Jan 30, 2022
Vimb - the vim like browser is a webkit based web browser that behaves like the vimperator plugin for the firefox and usage paradigms from the great editor vim.

Vimb - the vim like browser is a webkit based web browser that behaves like the vimperator plugin for the firefox and usage paradigms from the great editor vim. The goal of vimb is to build a completely keyboard-driven, efficient and pleasurable browsing-experience.

Dec 30, 2022
A collection of code snippets and examples showing syntax and capabilities of VEX language inside SideFX Houdini
A collection of code snippets and examples showing syntax and capabilities of VEX language inside SideFX Houdini

VEX tutorial A collection of code snippets and examples showing syntax and capabilities of VEX language inside SideFX Houdini by Juraj Tomori How to u

Dec 11, 2022
Visual Studio extension for assembly syntax highlighting and code completion in assembly files and the disassembly window
Visual Studio extension for assembly syntax highlighting and code completion in assembly files and the disassembly window

Asm-Dude Assembly syntax highlighting and code assistance for assembly source files and the disassembly window for Visual Studio 2015, 2017 and 2019.

Jan 6, 2023