You are not logged in.

#1 2015-09-18 01:53:21

padster
Member
Registered: 2012-03-14
Posts: 24
Website

First simple PKGBUILD. Could I get a once-over before submitting?

I found a nice utility for "fighting procrastination via the /etc/hosts file" on reddit earlier today and thought I'd check if it's in the AUR. It's not, so I thought it would be pretty simple to make a package for it.
Since I didn't really want to install the build dependencies and there were already precompiled binaries on the github page, I thought I'd make a binary package version, since there are often "foo" and "foo-git" packages, for example.

Anyways, it's a super basic pkgbuild that downloads the executable file, changes the permissions, and copies it to /usr/bin/. As it's my first package I thought I'd just post here to make sure it's okay.

Could someone take a look and make sure it's good to go? I've tested it on my system and it works fine.
The PKGBUILD is here

Thanks

EDIT: Looks like it's been updated since, still same idea, just new version number and sha256sum. Updated pkgbuild here

Last edited by padster (2015-09-18 02:14:44)

Offline

#2 2015-09-18 03:08:38

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: First simple PKGBUILD. Could I get a once-over before submitting?

Use install in the package function, rather than mkdir (you can then remove the prepare function).

Also, see https://aur.archlinux.org/packages/hostsblock


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#3 2015-09-18 03:21:45

progandy
Member
Registered: 2012-05-17
Posts: 5,184

Re: First simple PKGBUILD. Could I get a once-over before submitting?

If you wish to use the precompiled binary, please append -bin to the package name.


| alias CUTF='LANG=en_XX.UTF-8@POSIX ' |

Offline

#4 2015-09-18 07:25:59

tomk
Forum Fellow
From: Ireland
Registered: 2004-07-21
Posts: 9,839

Re: First simple PKGBUILD. Could I get a once-over before submitting?

padster wrote:

Since I didn't really want to install the build dependencies

Why not? Not being critical, just curious. Personally, I'd always choose to build from source over a pre-compiled binary.

Offline

#5 2015-09-18 19:30:12

padster
Member
Registered: 2012-03-14
Posts: 24
Website

Re: First simple PKGBUILD. Could I get a once-over before submitting?

jasonwryan wrote:

Use install in the package function, rather than mkdir (you can then remove the prepare function).

Also, see https://aur.archlinux.org/packages/hostsblock

Thanks, I'll do that. The other one looks like more of an ad-blocker. This one makes you do a little extra work to unblock stuff you want blocked temporarily.


progandy wrote:

If you wish to use the precompiled binary, please append -bin to the package name.

Will-do.

tomk wrote:
padster wrote:

Since I didn't really want to install the build dependencies

Why not? Not being critical, just curious. Personally, I'd always choose to build from source over a pre-compiled binary.

I just don't like having extra packages on my system. I'm not against compiling from source, I just figured if there was a version that I could just copy in without having to install a bunch of extra packages I'd rather do that than uninstall them afterwards.

Thanks, everyone, I'll update the PKGBUILD and post the new one here.

EDIT: Updated PKGBUILD

Last edited by padster (2015-09-18 19:37:53)

Offline

#6 2015-09-18 22:18:08

Lone_Wolf
Member
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 11,866

Re: First simple PKGBUILD. Could I get a once-over before submitting?

I just don't like having extra packages on my system. I'm not against compiling from source, I just figured if there was a version that I could just copy in without having to install a bunch of extra packages I'd rather do that than uninstall them afterwards.

https://wiki.archlinux.org/index.php/De … ean_Chroot

A simpler alternative is to use makepkg -Crs


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.


(A works at time B)  && (time C > time B ) ≠  (A works at time C)

Online

#7 2015-09-19 15:05:23

padster
Member
Registered: 2012-03-14
Posts: 24
Website

Re: First simple PKGBUILD. Could I get a once-over before submitting?

Lone_Wolf wrote:

I just don't like having extra packages on my system. I'm not against compiling from source, I just figured if there was a version that I could just copy in without having to install a bunch of extra packages I'd rather do that than uninstall them afterwards.

https://wiki.archlinux.org/index.php/De … ean_Chroot

A simpler alternative is to use makepkg -Crs

I've got my package up on the AUR now, I'll try this for making a -git version, thanks!

Offline

Board footer

Powered by FluxBB