Package Details: hblock 2.0.6-1

Git Clone URL: (read-only)
Package Base: hblock
Description: An adblocker that creates a hosts file from automatically downloaded blacklists
Upstream URL:
Keywords: adblock blacklist hosts
Licenses: MIT
Submitter: JustMeErazem
Maintainer: JustMeErazem
Last Packager: JustMeErazem
Votes: 3
Popularity: 1.245636
First Submitted: 2018-12-15 19:51
Last Updated: 2019-03-16 18:53

Latest Comments

1 2 Next › Last »

JustMeErazem commented on 2019-05-02 22:50

@kronikpillow, to enable the timer type sudo systemctl enable hblock.timer

kronikpillow commented on 2019-05-02 22:44

@JustMeErazem stange, I have the package installed, and with a second attempt i managed to install HBlock ... I ran hblock -b to generate the hosts file, now i just need to figgure out how to enable the timer :D

JustMeErazem commented on 2019-05-01 20:27

@kronikpillow Seems you don't have zip installed. I don't use Arch anymore so I won't update the package, but it seems zip should be added as a dependency.

You can fix this issue locally by installing the package "zip" and retry the installation of hblock.

kronikpillow commented on 2019-05-01 20:23

  • Parsing lists...
  • Remove carriage return
  • Transform to lowercase
  • Remove comments
  • Trim spaces
  • Match hosts lines
  • Remove reserved TLDs
  • Remove destination IPs
  • Sort entries
  • Apply format template
  • Generating output file...
  • 134670 blocked domains! 'resources/alt-formats/' './dist/hosts' './hblock' './resources' > 'dist/' 'resources/alt-formats/' './dist/hosts' './hblock' './resources' > 'dist/hosts_adblock.txt' 'resources/alt-formats/' './dist/hosts' './hblock' './resources' > 'dist/' 'resources/alt-formats/' './dist/hosts' './hblock' './resources' > 'dist/hosts_unbound.conf' 'resources/alt-formats/' './dist/hosts' './hblock' './resources' > 'dist/hosts_rpz.txt' resources/alt-formats/ line 18: zip: command not found resources/alt-formats/ line 18: zip: command not found make: [Makefile:62: dist/] Error 127 make: Waiting for unfinished jobs.... make: *** [Makefile:62: dist/] Error 127 ==> ERROR: A failure occurred in build(). Aborting... Error making: hblock ┌ 1 ~ └> $

JustMeErazem commented on 2019-03-21 10:52

@justcommenting The build section (the "make" command) apparently downloads the blacklists. So for now I will leave everything as it is.

Also the service isn't meant to be started using systemctl, but you can enable the timer so it will download the blacklists weekly (I think).

I have no intention of automatically enabling the timer, since like you said, stuff like that is against Arch rules.

justcommenting commented on 2019-03-17 09:06

@JustMeErazem The way the package now installs, I don't think we need to build anything. So just keep an empty build() {} instruction.

Moreover, I think you misunderstood me previously. I meant that just installing hblock.{service,timer} in systemd/system/ won't enable the service, and even then, without a systemctl start instruction, it won't start before a reboot, either; and everything would need a proper clean-up upon removal as well. Hence, the .install file.

However, it seems to be against Arch policy to autostart services, so we can forget that.

Just enabling the timer appears to be fine, though. A few standard packages do that. So I would add the following to package():

install -dm755 "${pkgdir}/usr/lib/systemd/system/"

ln -s ../hblock.timer "${pkgdir}/usr/lib/systemd/system/"

Lastly, when you remove a service, systemd doesn't clean up the timestamps as far as I know. So you may want to remove /var/lib/systemd/timers/stamp-hblock.timer either via post_remove() in an .install file or you touch it in package() when it doesn't exist, yet, in /var.

justcommenting commented on 2019-03-16 15:47


Yeah, you can use install -Dm644 as well. At the same time you can fix the location to /usr/lib/systemd/system, as is the arch linux style.

JustMeErazem commented on 2019-03-16 15:36


Do I have to use a separate file to enable the service or can I move the service and timer files and enable the service in the package() stage?

justcommenting commented on 2019-03-16 15:25

@JustMeErazem edit: mistakenly removed my comment :)

You need to change the make install line in package() to the following:

make DESTDIR="${pkgdir}/" SKIP_SERVICE_START=1 install

It would be nice if you also add a hblock.install file which would start and enable the systemd service after the installation.

JustMeErazem commented on 2019-03-16 15:24

The latest 2.0.5-5 version has fixed the build and sha265sum problems thanks to @justcommenting and folks from the arch BBS