1
0
mirror of https://github.com/kmein/niveum synced 2026-03-16 10:11:08 +01:00

feat: flameshot -> flameshot-once

This commit is contained in:
2021-12-28 14:48:09 +01:00
parent 0423429e02
commit 5b131a5a30
6 changed files with 40 additions and 25 deletions

View File

@@ -0,0 +1,11 @@
{
"url": "https://cgit.krebsco.de/nix-writers",
"rev": "c528cf970e292790b414b4c1c8c8e9d7e73b2a71",
"date": "2019-04-02T20:05:33+02:00",
"path": "/nix/store/wm5zhsha1a2iy0d582nlfi7604ayd1vz-nix-writers",
"sha256": "0xdivaca1hgbxs79jw9sv4gk4f81vy8kcyaff56hh2dgq2awyvw4",
"fetchLFS": false,
"fetchSubmodules": false,
"deepClone": false,
"leaveDotGit": false
}

View File

@@ -28,6 +28,7 @@ in {
};
};
overlays = [
(import <nix-writers/pkgs>)
(import <stockholm/krebs/5pkgs>)
(self: super: {
scripts = import <niveum/packages/scripts> { pkgs = super; lib = super.lib; };

View File

@@ -1,26 +1,24 @@
{ config, lib, pkgs, ... }:
{
home-manager.users.me = {
services.flameshot.enable = true;
{ lib, pkgs, ... }:
let
inherit (import <niveum/lib>) defaultApplications;
flameshot-once = pkgs.callPackage <stockholm/krebs/5pkgs/simple/flameshot-once> {};
in {
nixpkgs.overlays = [
(self: super: {
write =
super.callPackage <stockholm/krebs/5pkgs/simple/xwaitforwindow.nix> { };
})
];
xdg.configFile."flameshot/flameshot.ini".source = (pkgs.formats.ini {}).generate "flameshot.ini" {
General = {
disabledTrayIcon = true;
checkForUpdates = false;
contrastOpacity = 188;
savePath = "/tmp";
savePathFixed = true;
drawThickness = 0;
showStartupLaunchMessage = false;
filenamePattern = "shot_%F_%T";
};
};
systemd.user.services.flameshot.Unit.Requires = lib.mkForce [];
systemd.user.services.flameshot.Environment = {
# IMGUR_CREATE_URL = "https://p.krebsco.de/image";
# IMGUR_DELETE_URL = "https://p.krebsco.de/image/delete/%1";
PATH = "${config.home-manager.users.me.home.profileDirectory}/bin";
};
environment.systemPackages = [
(flameshot-once.override {
config.imgur = {
enable = true;
createUrl = "http://p.r/image";
deleteUrl = "http://p.r/image/delete/%1";
xdg-open.browser = (defaultApplications pkgs).browser;
};
config.timeout = 1000;
})
];
}

View File

@@ -233,8 +233,7 @@ in {
"${modifier}+F10" = "exec ${pkgs.redshift}/bin/redshift -x";
"${modifier}+F11" = "exec ${pkgs.xcalib}/bin/xcalib -invert -alter";
"${modifier}+F12" = "exec ${klem}/bin/klem";
"Print" = "exec flameshot gui -p /tmp";
"Print" = "exec flameshot-once";
"XF86AudioLowerVolume" = "exec --no-startup-id ${pkgs.pamixer}/bin/pamixer -d 5";
"XF86AudioMute" = "exec --no-startup-id ${pkgs.pamixer}/bin/pamixer -t";
"XF86AudioRaiseVolume" = "exec --no-startup-id ${pkgs.pamixer}/bin/pamixer -i 5";

View File

@@ -22,6 +22,7 @@ let
nixpkgs-unstable.git = gitFromJson .versions/nixpkgs-unstable.json // { shallow = true; };
home-manager.git = gitFromJson .versions/home-manager.json;
stockholm.git = gitFromJson .versions/stockholm.json;
nix-writers.git = gitFromJson .versions/nix-writers.json;
retiolum.git = gitFromJson .versions/retiolum.json;
nixpkgs-mozilla.git = gitFromJson .versions/nixpkgs-mozilla.json;
system-secrets.pass = {

View File

@@ -15,6 +15,11 @@ let
url = "https://github.com/NixOS/nixpkgs.git";
path = toString .versions/nixpkgs-unstable.json;
};
nix-writers = {
ref = "refs/heads/master";
url = "https://cgit.krebsco.de/nix-writers";
path = toString .versions/nix-writers.json;
};
home-manager = {
ref = "refs/heads/release-${release}";
url = "https://github.com/nix-community/home-manager.git";