1. When to use it
Use it when you need to distribute small internal tools without scattered manual installs.
makepkg | noarch | slack-desc | script | txz
2. Base setup
mkdir -p /tmp/pkg/usr/local/bin /tmp/pkg/install
install -m755 myscript.sh /tmp/pkg/usr/local/bin/myscript
printf 'myscript: myscript\n' > /tmp/pkg/install/slack-desc
makepkg -l y -c n /tmp/myscript-noarch-1.0-noarch-1.txz
Adjust host names, IPs, interfaces, paths, and versions to the real system before making the change persistent.
3. Quick verification
tar -tf /tmp/myscript-noarch-1.0-noarch-1.txz | head
upgradepkg --install-new /tmp/myscript-noarch-1.0-noarch-1.txz
ls /var/log/packages | grep myscript
Confirm that the output matches the expected state before considering the intervention complete.
4. Operational notes
Use noarch only for truly CPU-independent content, otherwise the package naming becomes misleading.
Quick checklist
[ ] Steps completed\n[ ] Config updated\n[ ] Tests executed\n[ ] Rollback ready\n[ ] Logs checked