Github messages for voidlinux
 help / color / mirror / Atom feed
From: voidlinux-github@inbox.vuxu.org
To: ml@inbox.vuxu.org
Subject: Re: [PR PATCH] [Updated] Add brightnessctl service to {, re}store screen brightness
Date: Wed, 10 Jul 2019 21:28:23 +0200	[thread overview]
Message-ID: <20190710192823.72QOt3f9fCpV19taU7kwHNpAPJfm7n85gNOczlyxpwY@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-12974@inbox.vuxu.org>

[-- Attachment #1: Type: text/plain, Size: 433 bytes --]

There is an updated pull request by mamins1376 against master on the void-packages repository

https://github.com/mamins1376/void-packages brightnessctl-runit-store
https://github.com/void-linux/void-packages/pull/12974

Add brightnessctl service to {,re}store screen brightness
Thought it would be nice to have this in the original package.

A patch file from https://github.com/void-linux/void-packages/pull/12974.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-brightnessctl-runit-store-12974.patch --]
[-- Type: application/text/x-diff, Size: 1628 bytes --]

From b5954570cbb9550901743997743b0a18ff7274f5 Mon Sep 17 00:00:00 2001
From: Mohammad Amin Sameti <mamins1376@gmail.com>
Date: Wed, 10 Jul 2019 23:32:31 +0430
Subject: [PATCH] Add brightnessctl service to store brightness

---
 srcpkgs/brightnessctl/files/brightness/finish | 2 ++
 srcpkgs/brightnessctl/files/brightness/run    | 5 +++++
 srcpkgs/brightnessctl/template                | 1 +
 3 files changed, 8 insertions(+)
 create mode 100755 srcpkgs/brightnessctl/files/brightness/finish
 create mode 100755 srcpkgs/brightnessctl/files/brightness/run

diff --git a/srcpkgs/brightnessctl/files/brightness/finish b/srcpkgs/brightnessctl/files/brightness/finish
new file mode 100755
index 00000000000..0fe19032089
--- /dev/null
+++ b/srcpkgs/brightnessctl/files/brightness/finish
@@ -0,0 +1,2 @@
+#!/bin/sh
+exec env XDG_RUNTIME_DIR=/var/lib brightnessctl -s > /dev/null
diff --git a/srcpkgs/brightnessctl/files/brightness/run b/srcpkgs/brightnessctl/files/brightness/run
new file mode 100755
index 00000000000..db42d6de09b
--- /dev/null
+++ b/srcpkgs/brightnessctl/files/brightness/run
@@ -0,0 +1,5 @@
+#!/bin/sh
+set -e
+# This will mkdir /var/lib/brightnessctl && store brightness values there
+env XDG_RUNTIME_DIR=/var/lib brightnessctl -r > /dev/null
+exec chpst -b brightness pause
diff --git a/srcpkgs/brightnessctl/template b/srcpkgs/brightnessctl/template
index 5480f496fa8..75632af1576 100644
--- a/srcpkgs/brightnessctl/template
+++ b/srcpkgs/brightnessctl/template
@@ -15,4 +15,5 @@ checksum=ac86de0df8dcfd60a415465daabca283192ceb8de6c53b8844e628709ccd0cef
 
 post_install() {
 	vlicense LICENSE
+	vsv brightness
 }

  parent reply	other threads:[~2019-07-10 19:28 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-10 19:12 [PR PATCH] Add brightnessctl service to {,re}store " voidlinux-github
2019-07-10 19:14 ` voidlinux-github
2019-07-10 19:28 ` voidlinux-github [this message]
2019-07-10 19:28 ` [PR PATCH] [Updated] Add brightnessctl service to {, re}store " voidlinux-github
2019-07-11  3:31 ` brightnessctl: Add service to store " voidlinux-github
2019-07-11  3:56 ` voidlinux-github
2019-07-11  4:48 ` voidlinux-github
2019-07-11  5:38 ` voidlinux-github
2019-07-11  7:22 ` voidlinux-github
2020-02-12 13:57 ` voidlinux-github
2020-11-05 12:06 ` [PR PATCH] [Closed]: " mamins1376

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190710192823.72QOt3f9fCpV19taU7kwHNpAPJfm7n85gNOczlyxpwY@z \
    --to=voidlinux-github@inbox.vuxu.org \
    --cc=ml@inbox.vuxu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).