From 0a6d1447db7d1f52517a4a4c47d4198451fd223e Mon Sep 17 00:00:00 2001 From: Katharina Fey Date: Sat, 5 Oct 2019 13:24:18 +0000 Subject: Adding LIBKOOKIE overlays directories Some of these package definitions are taken verbatim from KOOKIEPKGS, others from NIXCFG MASTER (which will be included in the history of this repository) --- overlays/default.nix | 31 ++ overlays/kookie/barrel-blog/default.nix | 32 ++ overlays/kookie/barrel-blog/meta.json | 6 + overlays/kookie/invoice/README.md | 54 ++++ overlays/kookie/invoice/default.nix | 28 ++ overlays/kookie/invoice/invoice.sh | 24 ++ overlays/kookie/invoice/template.tex | 141 +++++++++ overlays/kookie/spacekookie-de/default.nix | 31 ++ overlays/kookie/spacekookie-de/meta.json | 6 + overlays/patches/emacs-ergoemacs-mode/default.nix | 12 + .../emacs-ergoemacs-mode/menu_to_hyper.patch | 350 +++++++++++++++++++++ .../htop/0001-htop-untruncated-username.patch | 136 ++++++++ overlays/patches/htop/default.nix | 19 ++ overlays/patches/neomutt/1388.patch | 29 ++ overlays/patches/neomutt/default.nix | 13 + overlays/staging/nodemcu-uploader/default.nix | 23 ++ overlays/staging/pleroma/default.nix | 25 ++ 17 files changed, 960 insertions(+) create mode 100644 overlays/default.nix create mode 100644 overlays/kookie/barrel-blog/default.nix create mode 100644 overlays/kookie/barrel-blog/meta.json create mode 100644 overlays/kookie/invoice/README.md create mode 100644 overlays/kookie/invoice/default.nix create mode 100755 overlays/kookie/invoice/invoice.sh create mode 100644 overlays/kookie/invoice/template.tex create mode 100644 overlays/kookie/spacekookie-de/default.nix create mode 100644 overlays/kookie/spacekookie-de/meta.json create mode 100644 overlays/patches/emacs-ergoemacs-mode/default.nix create mode 100644 overlays/patches/emacs-ergoemacs-mode/menu_to_hyper.patch create mode 100644 overlays/patches/htop/0001-htop-untruncated-username.patch create mode 100644 overlays/patches/htop/default.nix create mode 100644 overlays/patches/neomutt/1388.patch create mode 100644 overlays/patches/neomutt/default.nix create mode 100644 overlays/staging/nodemcu-uploader/default.nix create mode 100644 overlays/staging/pleroma/default.nix diff --git a/overlays/default.nix b/overlays/default.nix new file mode 100644 index 00000000000..c3dfd293116 --- /dev/null +++ b/overlays/default.nix @@ -0,0 +1,31 @@ +/* Overlays in LIBKOOKIE are split into three parts + * + * patches: upstream but with cool stuff + * staging: things that might become upstream + * kookie: scripts and utils that won't leave LIBKOOKIE + */ + +self: super: + +with super; { + + barrel-blog = callPackage ./kookie/barrel-blog { }; + + invoice = callPackage ./kookie/invoice { }; + + spacekookie-de = callPackage ./kookie/spacekookie-de { }; + +} // { + + nodemcu-uploader = callPackage ./staging/nodemcu-uploader { }; + + pleroma = callPackage ./staging/pleroma { }; + +} // { + + emacs-ergoemacs-mode = callPackage ./patches/emacs-ergoemacs-mode { }; + + htop = callPackage ./patches/htop { }; + + neomutt = callPackages ./patches/neomutt { }; +} diff --git a/overlays/kookie/barrel-blog/default.nix b/overlays/kookie/barrel-blog/default.nix new file mode 100644 index 00000000000..68e8cf1825f --- /dev/null +++ b/overlays/kookie/barrel-blog/default.nix @@ -0,0 +1,32 @@ +{ stdenv, fetchFromGitHub, pkgs, ... }: + +let + json = with builtins; fromJSON (readFile ./meta.json); + master = json.rev; + masterSha256 = json.sha256; +in + stdenv.mkDerivation rec { + name = "barrel-blog"; + + src = fetchFromGitHub { + owner = "spacekookie"; + repo = "barrel"; + rev = master; + sha256 = masterSha256; + }; + + buildInputs = with pkgs.pythonPackages; [ pelican webassets markdown ]; + + installPhase = '' + cd docs/ + pelican content + cp -rv output $out + ''; + + meta = with stdenv.lib; { + description = "A static website running on https://barrel.spacekookie.de"; + homepage = "https://barrel.spacekookie.de"; + license = licenses.mit; + }; + } + diff --git a/overlays/kookie/barrel-blog/meta.json b/overlays/kookie/barrel-blog/meta.json new file mode 100644 index 00000000000..3f1a908d973 --- /dev/null +++ b/overlays/kookie/barrel-blog/meta.json @@ -0,0 +1,6 @@ +{ + "owner": "spacekookie", + "repo": "barrel", + "rev": "ee5a17c97ac5315388f015ce59c98da3b6a895ce", + "sha256": "0n566x8y87pc3ynxqj7sv7cwsj4fhpz2pwn2mhhyjyqpyrq0khfc" +} \ No newline at end of file diff --git a/overlays/kookie/invoice/README.md b/overlays/kookie/invoice/README.md new file mode 100644 index 00000000000..500fb5929fe --- /dev/null +++ b/overlays/kookie/invoice/README.md @@ -0,0 +1,54 @@ +# invoice + +A tool that generates invoices with `pandoc`, `xelatex` and `yaml`. +A descriptor file is required in order to make all of this work. +These are independent of the tooling and template and should be +client specific. Following is a small example of what it should +look like: + +```yaml +--- +invoice-nr: 2019-1234 +date: 2019-06-09 +author: Alice Anonymous +city: Metropolis +from: +- Cyberstreet 69 +- XX51F5 Metropolis +- alice.anonymous@mail.cyber +- + 69 (0) 13 37 13 12 +ustid: Your Tax ID here +bank: Evil Bank (i.e. a bank) +bank_iban: Your IBAN +bank_bic: Your Bank BIC +to: +- Client Name +- Client Address +- ... +VAT: 19 # Depends on the country you live in +service: +- description: Looking cool + price: 255 + details: + - Making all your other employees look silly + - Telling really bad jokes +- description: Being awesome + price: 615 + details: Its in the title! + +currency: EUR +lang: english + +# Typography and layout +fontsize: 10pt +geometry: a4paper, left=43mm, right=43mm, top=51mm, bottom=17mm +--- +``` + +Then point the script at this descriptor: + +``` +$ invoice clients/client_name.yml +``` + +This will then generate `clients/client_name.pdf` as an invoice diff --git a/overlays/kookie/invoice/default.nix b/overlays/kookie/invoice/default.nix new file mode 100644 index 00000000000..25c0fbb1ddb --- /dev/null +++ b/overlays/kookie/invoice/default.nix @@ -0,0 +1,28 @@ +{ stdenv, makeWrapper, coreutils, findutils, gawk, pandoc, gnumake, texlive }: + +stdenv.mkDerivation { + pname = "invoice"; + version = "0.1.0"; + src = ./.; + + nativeBuildInputs = [ makeWrapper ]; + + installPhase = '' + mkdir -p $out/{bin,share} + cp invoice.sh $out/bin/invoice + cp template.tex $out/share/ + + wrapProgram $out/bin/invoice \ + --set PATH $out/bin:${stdenv.lib.makeBinPath + [ coreutils findutils gawk gnumake pandoc texlive.combined.scheme-full ]} \ + --set TEMPLATE_FILE $out/share/template.tex + ''; + + + meta = with stdenv.lib; { + description = "Generate dynamic invoices based on yaml descriptors"; + homepage = "https://git.sr.ht/~spacekookie/kookiepkgs/"; + license = licenses.gpl3; + }; +} + diff --git a/overlays/kookie/invoice/invoice.sh b/overlays/kookie/invoice/invoice.sh new file mode 100755 index 00000000000..1374f9219d2 --- /dev/null +++ b/overlays/kookie/invoice/invoice.sh @@ -0,0 +1,24 @@ +#!/bin/sh + +set -ueo pipefail + +SOURCE=$1 + +if [ -z $SOURCE ]; then + echo "Usage: invoice " + exit 2 +fi + +TARGET=$(dirname $SOURCE) +ACCOUNT=$(basename $SOURCE .yml) + +# The reason behind this awk madness is that we want to be able to write +# a date as yyyy-mm-dd in the invoice descriptor, but LaTeX needs the +# date as three elements to fill in a {d}{m}{y} pattern. Thus we replace +# a simple "date" line with three seperate fields that we can then read +# from LaTeX +cat $SOURCE | xargs -d '\n' -L 1 \ + | awk -F '-' '{ if(match($0, /date/)) { gsub(/date: /,"", $1); \ + print "date_year: " $1 "\n" "date_month: " $2 "\n" "date_day: " $3 } \ + else { print $0} }' \ + | pandoc - -o $TARGET/$ACCOUNT.pdf --template=$TEMPLATE_FILE --pdf-engine=xelatex diff --git a/overlays/kookie/invoice/template.tex b/overlays/kookie/invoice/template.tex new file mode 100644 index 00000000000..33d12f5f6dc --- /dev/null +++ b/overlays/kookie/invoice/template.tex @@ -0,0 +1,141 @@ +%!TEX TS-program = xelatex +%!TEX encoding = UTF-8 Unicode + +\documentclass[$fontsize$, a4paper]{scrartcl} + +% LAYOUT +%-------------------------------- +\usepackage{geometry} +\geometry{$geometry$} +\pagenumbering{gobble} +\usepackage[document]{ragged2e} +\usepackage{scrlayer-scrpage} + +% TYPOGRAPHY +%-------------------------------- +\usepackage{fontspec} +\usepackage{xunicode} +\usepackage{xltxtra} + +\setlength{\parskip}{1em} + +% Command required by how Pandoc handles the list conversion +\providecommand{\tightlist} { + \setlength{\itemsep}{0pt}\setlength{\parskip}{0pt} +} + +% TABLE CUSTOMIZATION +%-------------------------------- +\usepackage{spreadtab} +\usepackage[compact]{titlesec} +\usepackage{hhline} +\usepackage{enumitem} +\usepackage{arydshln} + +\titlespacing*{\section}{0pt}{3pt}{-7pt} +\renewcommand{\arraystretch}{1.5} +\setlist{nolistsep} +\setlist[itemize]{leftmargin=0.5cm} +\setlength{\tabcolsep}{9pt} + + +% LANGUAGE +%-------------------------------- +$if(lang)$ +\usepackage{polyglossia} +\setmainlanguage{german} +$endif$ + +% PDF SETUP +%-------------------------------- +\usepackage[xetex, bookmarks, colorlinks, breaklinks]{hyperref} +\hypersetup +{ + pdfauthor={$author$}, + pdfsubject=Rechnungs Nr. $invoice-nr$, + pdftitle=Rechnungs Nr. $invoice-nr$, + linkcolor=blue, + citecolor=blue, + filecolor=black, + urlcolor=blue +} + +\usepackage[nodayofweek]{datetime} +\newdate{date}{$date_day$}{$date_month$}{$date_year$} +\date{\displaydate{date}} + +% DOCUMENT +%-------------------------------- + +\ohead{ + \textsc{\textbf{$author$}} \\ + $for(from)$ + \textsc{$from$} \\ + $endfor$ + \textsc{USt-IdNr: $ustid$} \\ + \vspace{1em} +} + +\begin{document} + +\vspace{1em} + +\normalsize \sffamily +$for(to)$ +$to$\\ +$endfor$ + +\vspace{6em} + +\begin{flushright} + \small + $city$, \displaydate{date} +\end{flushright} + +\vspace{1em} + +\section*{\textsc{Rechnung} \textsc{\#$invoice-nr$}} +\footnotesize +\newcounter{pos} +\setcounter{pos}{0} +\STautoround*{2} % Get spreadtab to always display the decimal part +$if(commasep)$\STsetdecimalsep{,}$endif$ % Use comma as decimal separator + +\begin{spreadtab}{{tabular}[t t t]{lp{8.2cm}r}} + \hdashline[1pt/1pt] + @ \noalign{\vskip 2mm} \textbf{Pos.} & @ \textbf{Description} & @ \textbf{Prices in $currency$} \\ \hline + $for(service)$ @ \noalign{\vskip 2mm} \refstepcounter{pos} \thepos + & @ $service.description$ + $if(service.details)$\newline \begin{itemize} + $for(service.details)$\scriptsize \item $service.details$ + $endfor$ \end{itemize} + $endif$ & $service.price$\\$endfor$ \noalign{\vskip 2mm} \hline + $if(VAT)$ + @ & @ \multicolumn{1}{r}{Subtotal:} & :={sum(c1:[0,-1])} \\ \hhline{~~-} + @ & @ \multicolumn{1}{r}{VAT $VAT$\%:} & $VAT$/100*[0,-1] \\ \hhline{~~-} + $else$ + @ & @ \multicolumn{1}{r}{Subtotal:} & :={sum(c1:[0,-1])} \\ \hhline{~~-} + @ & @ \multicolumn{1}{r}{USt. Nullregelung:} & 0 \\ \hhline{~~-} + $endif$ + @ & @ \multicolumn{1}{r}{\textbf{Total:}} & \textbf{:={$if(VAT)$[0,-1]+[0,-2]$else$[0,-2]$endif$}} \\ \hhline{~~-} +\end{spreadtab} + +\vspace{15mm} + +\sffamily +\small + +Bitte überweisen Sie den folgenden Betrag in den nächsten 14 Tagen: + +\strong{Kontoinhaber}: $author$ \\ +\strong{Kreditinstitut}: $bank$ \\ +\strong{IBAN}: $bank_iban$ \\ +\strong{BIC}: $bank_bic$ + +Mit freundlichen Grüßen, + +\medskip + +$author$ + +\end{document} diff --git a/overlays/kookie/spacekookie-de/default.nix b/overlays/kookie/spacekookie-de/default.nix new file mode 100644 index 00000000000..a15af12b5fa --- /dev/null +++ b/overlays/kookie/spacekookie-de/default.nix @@ -0,0 +1,31 @@ +{ stdenv, fetchFromGitHub, pkgs, ... }: + +let + json = with builtins; fromJSON (readFile ./meta.json); + master = json.rev; + masterSha256 = json.sha256; +in + stdenv.mkDerivation rec { + name = "spacekookie.de"; + + src = fetchFromGitHub { + owner = "spacekookie"; + repo = "website"; + rev = master; + sha256 = masterSha256; + }; + + buildInputs = with pkgs.python3Packages; [ pelican webassets markdown ]; + + installPhase = '' + pelican content + cp -rv output $out + ''; + + meta = with stdenv.lib; { + description = "The `about` and `blog` part of spacekookie.de"; + homepage = "https://spacekookie.de"; + license = licenses.mit; + }; + } + diff --git a/overlays/kookie/spacekookie-de/meta.json b/overlays/kookie/spacekookie-de/meta.json new file mode 100644 index 00000000000..a793b45c5a6 --- /dev/null +++ b/overlays/kookie/spacekookie-de/meta.json @@ -0,0 +1,6 @@ +{ + "owner": "spacekookie", + "repo": "website", + "rev": "beb5a1bbd298ceb1646902cc3ee7255f50f54542", + "sha256": "1nhcp87ixnfalir8bi3gnx4q30f2dava0g6przzkp2mkdiwnh1fm" +} \ No newline at end of file diff --git a/overlays/patches/emacs-ergoemacs-mode/default.nix b/overlays/patches/emacs-ergoemacs-mode/default.nix new file mode 100644 index 00000000000..112829b9ded --- /dev/null +++ b/overlays/patches/emacs-ergoemacs-mode/default.nix @@ -0,0 +1,12 @@ +/* CUSTOM ERGOEMACS-MODE PATCH + * + * The ergonomic keybinding minor-mode I use in emacs + * (ergoemacs) uses MENU as a modifier key. Instead + * I would like to use HYPER. + */ +{ pkgs, ... }: + +with pkgs.emacsPackagesNg; +ergoemacs-mode.overrideAttrs ({ patches ? [], ... }: { + patches = patches ++ [ ./menu_to_hyper.patch ]; +}) diff --git a/overlays/patches/emacs-ergoemacs-mode/menu_to_hyper.patch b/overlays/patches/emacs-ergoemacs-mode/menu_to_hyper.patch new file mode 100644 index 00000000000..c6ab0a0db80 --- /dev/null +++ b/overlays/patches/emacs-ergoemacs-mode/menu_to_hyper.patch @@ -0,0 +1,350 @@ +From 2f9bad50132d0278c5581934c4bc54cd10244399 Mon Sep 17 00:00:00 2001 +From: Katharina Fey +Date: Sun, 8 Sep 2019 17:19:15 +0100 +Subject: [PATCH] Switching `` to `` + +The idea behind this change is that my X230 doesn't have easy access +to a `Menu` key. Furthermore, while it is possible for me to remap a +different key (say CAPSLOCK) to `Menu`, it also adds the problem if +stray control characters when hitting it outside of emacs. This has +shown to be a problem quite frequently, which has resulted in me not +being able to use many of the `Menu` modified combinations in +ergoemacs. + +While I experimented around replacing X input events via an external +tool [1], the easier solution to this problem is to not use `Menu` as +a modifier for ergoemacs. Unfortunately this is not a tweakable +variable that I can adjust in my emacs configuration, but instead +needed to patch (thus this patch). + +My regular emacs config [2] has no knowledge of this change, neither +will yours. Instead of using `Menu`, the `Hyper` key is introduced to +the keyboard layout. The rationale behind `Hyper` is that it is a +modifier that is otherwise not present on most keyboards, and also +doesn't add a stray control character when pressed outside of emacs. +--- + ergoemacs-mode.el | 2 +- + ergoemacs-test.el | 20 +++--- + ergoemacs-themes.el | 98 +++++++++++++++--------------- + ergoemacs-translate.el | 2 +- + kbd-ergo.html | 6 +- + o-blog-template/style/js/keymap.js | 4 +- + web.org | 6 +- + 7 files changed, 69 insertions(+), 69 deletions(-) + +diff --git a/ergoemacs-mode.el b/ergoemacs-mode.el +index 5b18155..1126414 100644 +--- a/ergoemacs-mode.el ++++ b/ergoemacs-mode.el +@@ -1189,7 +1189,7 @@ color. Otherwise this will be nil A color string as passed to + "" + "" + "" +- "" "" ++ "" "" + "RET" "ESC" "DEL" "TAB" + "" + "" +diff --git a/ergoemacs-test.el b/ergoemacs-test.el +index c62330a..34b98eb 100644 +--- a/ergoemacs-test.el ++++ b/ergoemacs-test.el +@@ -988,7 +988,7 @@ Should test issue #142" + nil + (if (eq system-type 'windows-nt) + " m c" +- " m c") nil nil "") t))) ++ " m c") nil nil "") t))) + + (ert-deftest ergoemacs-test-global-key-set-apps-m-c-before-2 () + "Test setting m c before loading (define-key)." +@@ -999,7 +999,7 @@ Should test issue #142" + nil + (if (eq system-type 'windows-nt) + " m c" +- " m c") 'define-key nil "") t))) ++ " m c") 'define-key nil "") t))) + + (ert-deftest ergoemacs-test-global-key-set-m-semi-before () + "Test setting M-; before loading." +@@ -1020,7 +1020,7 @@ Should test issue #142" + nil + (if (eq system-type 'windows-nt) + "" +- "")) t))) ++ "")) t))) + + + (ert-deftest ergoemacs-test-global-key-set-apps-before-2 () +@@ -1032,7 +1032,7 @@ Should test issue #142" + nil + (if (eq system-type 'windows-nt) + "" +- "") 'define-key) t))) ++ "") 'define-key) t))) + + (ert-deftest ergoemacs-test-global-key-set-apps-m-before () + "Test setting m before loading." +@@ -1043,7 +1043,7 @@ Should test issue #142" + nil + (if (eq system-type 'windows-nt) + " m" +- " m") nil nil "") t))) ++ " m") nil nil "") t))) + + (ert-deftest ergoemacs-test-global-key-set-apps-m-before-2 () + "Test setting m before loading (define-key)." +@@ -1054,7 +1054,7 @@ Should test issue #142" + nil + (if (eq system-type 'windows-nt) + " m" +- " m") 'define-key nil "") t))) ++ " m") 'define-key nil "") t))) + + (ert-deftest ergoemacs-test-global-key-set-apps-m-after () + "Test setting m after loading" +@@ -1065,7 +1065,7 @@ Should test issue #142" + 'after + (if (eq system-type 'windows-nt) + " m" +- " m") nil nil "") t))) ++ " m") nil nil "") t))) + + + (ert-deftest ergoemacs-test-global-key-set-apps-m-after-2 () +@@ -1077,7 +1077,7 @@ Should test issue #142" + 'after + (if (eq system-type 'windows-nt) + " m" +- " m") 'define-key nil "") t))) ++ " m") 'define-key nil "") t))) + + (ert-deftest ergoemacs-test-global-key-set-apps-m-c-after () + "Test setting m c after loading." +@@ -1088,7 +1088,7 @@ Should test issue #142" + 'after + (if (eq system-type 'windows-nt) + " m c" +- " m c") nil nil "") t))) ++ " m c") nil nil "") t))) + + (ert-deftest ergoemacs-test-global-key-set-apps-m-c-after-2 () + "Test setting m c after loading (define-key)." +@@ -1099,7 +1099,7 @@ Should test issue #142" + 'after + (if (eq system-type 'windows-nt) + " m c" +- " m c") 'define-key nil "") t))) ++ " m c") 'define-key nil "") t))) + + + (ert-deftest ergoemacs-test-global-key-set-after-220 () +diff --git a/ergoemacs-themes.el b/ergoemacs-themes.el +index fdc7a13..6bfa074 100644 +--- a/ergoemacs-themes.el ++++ b/ergoemacs-themes.el +@@ -1138,55 +1138,55 @@ + (ergoemacs-component ergoemacs-banish-shift () + "Banish Shift Combinations with SPC" + :variable-reg "" +- (global-set-key (kbd " SPC SPC") (kbd "_")) ;low line (underscore) +- (global-set-key (kbd " SPC RET") (kbd "-")) +- (global-set-key (kbd " SPC '") (kbd "\"")) +- (global-set-key (kbd " SPC ,") (kbd "<")) +- (global-set-key (kbd " SPC -") (kbd "_")) +- (global-set-key (kbd " SPC .") (kbd ">")) +- (global-set-key (kbd " SPC /") (kbd "?")) +- (global-set-key (kbd " SPC ;") (kbd ":")) +- (global-set-key (kbd " SPC =") (kbd "+")) +- (global-set-key (kbd " SPC \\") (kbd "|")) +- (global-set-key (kbd " SPC `") (kbd "~")) +- +- (global-set-key (kbd " SPC 0") (kbd ")")) +- (global-set-key (kbd " SPC 1") (kbd "!")) +- (global-set-key (kbd " SPC 2") (kbd "@")) +- (global-set-key (kbd " SPC 3") (kbd "#")) +- (global-set-key (kbd " SPC 4") (kbd "$")) +- (global-set-key (kbd " SPC 5") (kbd "%")) +- (global-set-key (kbd " SPC 6") (kbd "^")) +- (global-set-key (kbd " SPC 7") (kbd "&")) +- (global-set-key (kbd " SPC 8") (kbd "*")) +- (global-set-key (kbd " SPC 9") (kbd "(")) +- +- (global-set-key (kbd " SPC a") (kbd "A")) +- (global-set-key (kbd " SPC b") (kbd "B")) +- (global-set-key (kbd " SPC c") (kbd "C")) +- (global-set-key (kbd " SPC d") (kbd "D")) +- (global-set-key (kbd " SPC e") (kbd "E")) +- (global-set-key (kbd " SPC f") (kbd "F")) +- (global-set-key (kbd " SPC g") (kbd "G")) +- (global-set-key (kbd " SPC h") (kbd "H")) +- (global-set-key (kbd " SPC i") (kbd "I")) +- (global-set-key (kbd " SPC j") (kbd "J")) +- (global-set-key (kbd " SPC k") (kbd "K")) +- (global-set-key (kbd " SPC l") (kbd "L")) +- (global-set-key (kbd " SPC m") (kbd "M")) +- (global-set-key (kbd " SPC n") (kbd "N")) +- (global-set-key (kbd " SPC o") (kbd "O")) +- (global-set-key (kbd " SPC p") (kbd "P")) +- (global-set-key (kbd " SPC q") (kbd "Q")) +- (global-set-key (kbd " SPC r") (kbd "R")) +- (global-set-key (kbd " SPC s") (kbd "S")) +- (global-set-key (kbd " SPC t") (kbd "T")) +- (global-set-key (kbd " SPC u") (kbd "U")) +- (global-set-key (kbd " SPC v") (kbd "V")) +- (global-set-key (kbd " SPC w") (kbd "W")) +- (global-set-key (kbd " SPC x") (kbd "X")) +- (global-set-key (kbd " SPC y") (kbd "Y")) +- (global-set-key (kbd " SPC z") (kbd "Z"))) ++ (global-set-key (kbd " SPC SPC") (kbd "_")) ;low line (underscore) ++ (global-set-key (kbd " SPC RET") (kbd "-")) ++ (global-set-key (kbd " SPC '") (kbd "\"")) ++ (global-set-key (kbd " SPC ,") (kbd "<")) ++ (global-set-key (kbd " SPC -") (kbd "_")) ++ (global-set-key (kbd " SPC .") (kbd ">")) ++ (global-set-key (kbd " SPC /") (kbd "?")) ++ (global-set-key (kbd " SPC ;") (kbd ":")) ++ (global-set-key (kbd " SPC =") (kbd "+")) ++ (global-set-key (kbd " SPC \\") (kbd "|")) ++ (global-set-key (kbd " SPC `") (kbd "~")) ++ ++ (global-set-key (kbd " SPC 0") (kbd ")")) ++ (global-set-key (kbd " SPC 1") (kbd "!")) ++ (global-set-key (kbd " SPC 2") (kbd "@")) ++ (global-set-key (kbd " SPC 3") (kbd "#")) ++ (global-set-key (kbd " SPC 4") (kbd "$")) ++ (global-set-key (kbd " SPC 5") (kbd "%")) ++ (global-set-key (kbd " SPC 6") (kbd "^")) ++ (global-set-key (kbd " SPC 7") (kbd "&")) ++ (global-set-key (kbd " SPC 8") (kbd "*")) ++ (global-set-key (kbd " SPC 9") (kbd "(")) ++ ++ (global-set-key (kbd " SPC a") (kbd "A")) ++ (global-set-key (kbd " SPC b") (kbd "B")) ++ (global-set-key (kbd " SPC c") (kbd "C")) ++ (global-set-key (kbd " SPC d") (kbd "D")) ++ (global-set-key (kbd " SPC e") (kbd "E")) ++ (global-set-key (kbd " SPC f") (kbd "F")) ++ (global-set-key (kbd " SPC g") (kbd "G")) ++ (global-set-key (kbd " SPC h") (kbd "H")) ++ (global-set-key (kbd " SPC i") (kbd "I")) ++ (global-set-key (kbd " SPC j") (kbd "J")) ++ (global-set-key (kbd " SPC k") (kbd "K")) ++ (global-set-key (kbd " SPC l") (kbd "L")) ++ (global-set-key (kbd " SPC m") (kbd "M")) ++ (global-set-key (kbd " SPC n") (kbd "N")) ++ (global-set-key (kbd " SPC o") (kbd "O")) ++ (global-set-key (kbd " SPC p") (kbd "P")) ++ (global-set-key (kbd " SPC q") (kbd "Q")) ++ (global-set-key (kbd " SPC r") (kbd "R")) ++ (global-set-key (kbd " SPC s") (kbd "S")) ++ (global-set-key (kbd " SPC t") (kbd "T")) ++ (global-set-key (kbd " SPC u") (kbd "U")) ++ (global-set-key (kbd " SPC v") (kbd "V")) ++ (global-set-key (kbd " SPC w") (kbd "W")) ++ (global-set-key (kbd " SPC x") (kbd "X")) ++ (global-set-key (kbd " SPC y") (kbd "Y")) ++ (global-set-key (kbd " SPC z") (kbd "Z"))) + + (ergoemacs-component menu-bar-file () + "File menu" +diff --git a/ergoemacs-translate.el b/ergoemacs-translate.el +index a3b9f88..997325b 100644 +--- a/ergoemacs-translate.el ++++ b/ergoemacs-translate.el +@@ -313,7 +313,7 @@ variants are created using `ergoemacs-translate--apply-funs'." + (defun ergoemacs-translate--define-key (keymap key def) + "Similar to `define-key', with the following differences: + - Both the Meta and escape sequences are bound. +-- Both and key sequences are bound. ++- Both and key sequences are bound. + - `ergoemacs-mode' advice to `define-key' is supressed. + + KEYMAP is the keymap that will be used for the definition. +diff --git a/kbd-ergo.html b/kbd-ergo.html +index faf8ee8..13adc89 100644 +--- a/kbd-ergo.html ++++ b/kbd-ergo.html +@@ -47,7 +47,7 @@ document.getElementById('canvas').innerHTML="This page is built with SVG jQuery + + } + kbd_layout = ["", "`", "1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "-", "=", "", "", "", "q", "w", "f", "p", "g", "j", "l", "u", "y", ";", "[", "]", "\\", "", "", "a", "r", "s", "t", "d", "h", "n", "e", "i", "o", "'", "", "", "", "", "z", "x", "c", "v", "b", "k", "m", ",", ".", "\/", "", "", "", "", "~", "!", "@", "#", "$", "%", "^", "&", "*", "(", ")", "_", "+", "", "", "", "Q", "W", "F", "P", "G", "J", "L", "U", "Y", ":", "{", "}", "|", "", "", "A", "R", "S", "T", "D", "H", "N", "E", "I", "O", "\"", "", "", "", "", "Z", "X", "C", "V", "B", "K", "M", "<", ">", "?", "", "", ""]; +-var_layout = {"M-n":"\u2190 char", "M-i":"\u2192 char", "M-u":"\u2191 line", "M-e":"\u2193 line", "M-C-n":"\u2190 word", "M-C-i":"\u2192 word", "M-C-u":"\u2191 \u00b6", "M-C-e":"\u2193 \u00b6", "M-l":"\u2190 word", "M-y":"\u2192 word", "M-L":"\u2190 \u00b6", "M-Y":"\u2192 \u00b6", "M-h":"\u2190 line\/*", "M-H":"\u2192 line\/*", "M-U":"\u2191 page", "M-E":"\u2193 page", "M-k":"\u2191 Top*", "M-K":"\u2193 Bottom*", "M-N":"\u2190 bracket", "M-I":"\u2192 bracket", "M-j":"\u2192 isearch", "M-J":"\u2190 isearch", "M-;":"recenter", "M-s":"\u232b char", "M-t":"\u2326 char", "M-f":"\u232b word", "M-p":"\u2326 word", "M-x":"\u2702 region", "M-c":"copy", "M-v":"paste", "M-V":"paste \u2191", "M-C":"copy all", "M-X":"\u2702 all", "M-Z":"\u21b7 redo", "M-z":"\u21b6 undo", "M-d":"\u2326 line", "M-D":"\u232b line", "M-S-SPC":"Mark Paragraph", "M-w":"\u2327 white", "M-'":"cmt dwim", "M-?":"tog. camel", "M-\/":"tog. case", "M-g":"\u21af compl", "M-G":"flyspell", "M-q":"fill\/unfill \u00b6", "":null, "M-SPC":"Set Mark", "M-a":"M-x", "M-A":"shell cmd", "M-r":"next pane", "M-R":"prev pane", "M-~":"prev frame", "M-`":"next frame", "M-5":"rep", "M-%":"rep reg", "M-3":"x other pane", "M-2":"x pane", "M-4":"split |", "M-$":"split \u2014", "M-8":"\u2190region\u2192", "M-*":"\u2190quote\u2192", "M-6":"Sel. Block", "M-7":"Sel. Line", "M-b":"Ace Jump", " 2":"x pane", " 3":"x other pane", " 4":"split \u2014", " 5":"rep", " ":"\u2702 all", " ":"copy all", " ":"M-x", " TAB":"indent-region", " SPC":"Set Mark", " a":"Sel All", " s":"Ctl-x", " t":"Ctl-c", " h":"Help", " h '":null, " h 1":null, " h 2":null, " h 3":null, " h 4":null, " h 5":null, " h 7":null, " h 8":null, " h 9":null, " h `":null, " h m":null, " h y":null, " h z":null, " h Z":null, " u":"Alt+Shift", " e":"Alt+mode", " m":"C-c C-c", " r":"Save", " y":"Open", " d":"C-u", " w":"Close", " x":"\u2702 region", " c":"copy", " v":"paste", " b":"\u21b7 redo", " g":"switch buf", " z":"\u21b6 undo", " k a":"agenda", " k A":"capture", " k c":"calc", " k d":"dired", " k e":"eshell", " k f":"OS Dir", " k g":"grep", " k m":"magit", " k o":"OS Open", " k r":"R", " k s":"shell", " k g":"capture", " k G":"agenda", " p":"Goto"}; ++var_layout = {"M-n":"\u2190 char", "M-i":"\u2192 char", "M-u":"\u2191 line", "M-e":"\u2193 line", "M-C-n":"\u2190 word", "M-C-i":"\u2192 word", "M-C-u":"\u2191 \u00b6", "M-C-e":"\u2193 \u00b6", "M-l":"\u2190 word", "M-y":"\u2192 word", "M-L":"\u2190 \u00b6", "M-Y":"\u2192 \u00b6", "M-h":"\u2190 line\/*", "M-H":"\u2192 line\/*", "M-U":"\u2191 page", "M-E":"\u2193 page", "M-k":"\u2191 Top*", "M-K":"\u2193 Bottom*", "M-N":"\u2190 bracket", "M-I":"\u2192 bracket", "M-j":"\u2192 isearch", "M-J":"\u2190 isearch", "M-;":"recenter", "M-s":"\u232b char", "M-t":"\u2326 char", "M-f":"\u232b word", "M-p":"\u2326 word", "M-x":"\u2702 region", "M-c":"copy", "M-v":"paste", "M-V":"paste \u2191", "M-C":"copy all", "M-X":"\u2702 all", "M-Z":"\u21b7 redo", "M-z":"\u21b6 undo", "M-d":"\u2326 line", "M-D":"\u232b line", "M-S-SPC":"Mark Paragraph", "M-w":"\u2327 white", "M-'":"cmt dwim", "M-?":"tog. camel", "M-\/":"tog. case", "M-g":"\u21af compl", "M-G":"flyspell", "M-q":"fill\/unfill \u00b6", "":null, "M-SPC":"Set Mark", "M-a":"M-x", "M-A":"shell cmd", "M-r":"next pane", "M-R":"prev pane", "M-~":"prev frame", "M-`":"next frame", "M-5":"rep", "M-%":"rep reg", "M-3":"x other pane", "M-2":"x pane", "M-4":"split |", "M-$":"split \u2014", "M-8":"\u2190region\u2192", "M-*":"\u2190quote\u2192", "M-6":"Sel. Block", "M-7":"Sel. Line", "M-b":"Ace Jump", " 2":"x pane", " 3":"x other pane", " 4":"split \u2014", " 5":"rep", " ":"\u2702 all", " ":"copy all", " ":"M-x", " TAB":"indent-region", " SPC":"Set Mark", " a":"Sel All", " s":"Ctl-x", " t":"Ctl-c", " h":"Help", " h '":null, " h 1":null, " h 2":null, " h 3":null, " h 4":null, " h 5":null, " h 7":null, " h 8":null, " h 9":null, " h `":null, " h m":null, " h y":null, " h z":null, " h Z":null, " u":"Alt+Shift", " e":"Alt+mode", " m":"C-c C-c", " r":"Save", " y":"Open", " d":"C-u", " w":"Close", " x":"\u2702 region", " c":"copy", " v":"paste", " b":"\u21b7 redo", " g":"switch buf", " z":"\u21b6 undo", " k a":"agenda", " k A":"capture", " k c":"calc", " k d":"dired", " k e":"eshell", " k f":"OS Dir", " k g":"grep", " k m":"magit", " k o":"OS Open", " k r":"R", " k s":"shell", " k g":"capture", " k G":"agenda", " p":"Goto"}; + fix_layout = {"":"\u21b6 undo", "":"\u21b6 undo", "C-z":"\u21b6 undo", "":"\u21b7 redo", "":"\u21b7 redo", "C-Z":"\u21b7 redo", "":null, " ":null, "":null, "":null, " ":null, "":"\u2702 region", "":"\u2702 region", "C-c ":null, "C-c":"Copy", "":"Copy", "":"\u2702 all", "":"Copy all", "":"paste \u2191", "C-V":"paste \u2191", "":"paste", "":"paste", "C-v":"paste", "C-N":"New Frame", "":"\u2326 char", "":"\u2326 word", "":"\u2326 word", "":"\u2190 line\/\u00b6", "":"\u2192 line\/\u00b6", "":"\u2191 Top", "":"\u2193 Bottom", "":"\u2190 word", "":"\u2192 word", "":"\u2192 \u00b6", "":"\u2192 \u00b6", "M-RET":"Newline & Indent", "C-r":"Revert", "":"tog. case", "":"\u2702 all", "":"Copy all", "":"\u00d7 Frame", "":null, "":null, "":null, "":null, "":null, "":"Previous", "":"Next", " '":null, " 1":null, " 2":null, " 3":null, " 4":null, " 5":null, " 7":null, " 8":null, " 9":null, " `":null, " m":null, " o":null, "":"copy", "":"Alt mode", "C-+":"+Font Size", "C--":"-Font Size", "C-.":"Quit", "C-\/":"Info", "C-0":null, "C-":null, "C-":null, "C-":null, "C-=":"+Font Size", "C-?":"Info", "C-S-":null, "C-S-":null, "C-C":"Copy", "C-F":"Occur", "C-O":"OS Open", "C-S":"Save As", "C-T":"Open Last", "C-W":"\u00d7 Frame", "C-X":"Cut", "C-`":"\u2194 Frame", "C-a":"Select all", "C-f":"Search", "C-h '":null, "C-h 1":null, "C-h 2":null, "C-h 3":null, "C-h 4":null, "C-h 5":null, "C-h 7":null, "C-h 8":null, "C-h 9":null, "C-h `":null, "C-h m":null, "C-h o":null, "C-l":"Goto", "C-n":"New Buffer", "C-o":"Edit File", "C-p":"Print", "C-s":"Save", "C-w":"Close Buf.", "C-x ":null, "C-x C-b":null, "C-x":"Cut", "C-y":"\u21b7 redo", "M-S-":null, "M-S-":null}; + function getText(textType, textNumber){ + var ret = " "; +@@ -74,7 +74,7 @@ function getText(textType, textNumber){ + + } else { + if (textType == "AA"){ +- ret = " "; ++ ret = " "; + } else if (textType == "CC"){ + ret = "C-"; + } else if (textType == "CS"){ +@@ -110,7 +110,7 @@ function getText(textType, textNumber){ + else if (textType == "M") + ret = "M-" + else if (textType == "A") +- ret = " " ++ ret = " " + ret = ret + kbd_layout[textNumber]; + if (!(var_layout[ret] == undefined)){ + ret = var_layout[ret] + ' '; +diff --git a/o-blog-template/style/js/keymap.js b/o-blog-template/style/js/keymap.js +index 2f0543f..2fba777 100644 +--- a/o-blog-template/style/js/keymap.js ++++ b/o-blog-template/style/js/keymap.js +@@ -74,7 +74,7 @@ function getText(textType, textNumber){ + + } else { + if (textType == "AA"){ +- ret = " "; ++ ret = " "; + } else if (textType == "CC"){ + ret = "C-"; + } else if (textType == "CS"){ +@@ -110,7 +110,7 @@ function getText(textType, textNumber){ + else if (textType == "M") + ret = "M-" + else if (textType == "A") +- ret = " " ++ ret = " " + ret = ret + kbd_layout[layout][textNumber]; + if (var_layouts[theme] && !(var_layouts[theme][ret] == undefined)){ + ret = var_layouts[theme][ret] + ' '; +diff --git a/web.org b/web.org +index 6553a9d..0278968 100644 +--- a/web.org ++++ b/web.org +@@ -1729,7 +1729,7 @@ For your information, an "unchorded" filter/translation would translate: + - Press Menu again to go back to the unchorded keyboard filter.* + ** Ergoemacs Key Chord Reduction + **** Movement without key-chords +-***** Method #1 -- Movement mode ++***** Method #1 -- Movement mode + One can enable movement without key-chords as follows: + - On QWERTY, press [Menu] [k] and then the movement key. This key is + repeatable. Therefore [Menu] [k] [k] [k] would move the cursor down +@@ -1822,7 +1822,7 @@ is done by: + ~/.emacs.d/init.el) as follows: + + #+BEGIN_SRC emacs-lisp +-(define-key key-translation-map (kbd "") (kbd "")) ++(define-key key-translation-map (kbd "") (kbd "")) + #+END_SRC + + *** Why don't you use the standard emacs key notation? +@@ -1912,7 +1912,7 @@ Adding keys for moving around words and deleting words. + file:ergoemacs-extras/lvl2/ergoemacs-layout-us.png + + **** Level 3 +-Full ergoemacs keyset without the / unchorded keys. ++Full ergoemacs keyset without the / unchorded keys. + #+BEGIN_SRC emacs-lisp + (setq ergoemacs-theme nil) + (ergoemacs-theme-option-off '(apps apps-apps apps-punctuation apps-swap)) +-- +2.22.0 + diff --git a/overlays/patches/htop/0001-htop-untruncated-username.patch b/overlays/patches/htop/0001-htop-untruncated-username.patch new file mode 100644 index 00000000000..1456cf04362 --- /dev/null +++ b/overlays/patches/htop/0001-htop-untruncated-username.patch @@ -0,0 +1,136 @@ +From: Alyssa Ross +Subject: [PATCH v2] Make "spacekookie" fit untruncated as a user name +Date: Fri, 15 Mar 2019 18:18:22 +0000 + +--- +This version of the increases the length of the column header as well as +the values, so columns after USER don't have misaligned headers. + + Process.c | 10 +++++----- + darwin/Platform.c | 2 +- + dragonflybsd/DragonFlyBSDProcess.c | 2 +- + freebsd/FreeBSDProcess.c | 2 +- + linux/LinuxProcess.c | 2 +- + openbsd/OpenBSDProcess.c | 2 +- + solaris/SolarisProcess.c | 2 +- + unsupported/Platform.c | 2 +- + 8 files changed, 12 insertions(+), 12 deletions(-) + +diff --git a/Process.c b/Process.c +index 54c41af..41d30a3 100644 +--- a/Process.c ++++ b/Process.c +@@ -480,13 +480,13 @@ void Process_writeField(Process* this, RichString* str, ProcessField field) { + if (Process_getuid != (int) this->st_uid) + attr = CRT_colors[PROCESS_SHADOW]; + if (this->user) { +- xSnprintf(buffer, n, "%-9s ", this->user); ++ xSnprintf(buffer, n, "%-11s ", this->user); + } else { +- xSnprintf(buffer, n, "%-9d ", this->st_uid); ++ xSnprintf(buffer, n, "%-11d ", this->st_uid); + } +- if (buffer[9] != '\0') { +- buffer[9] = ' '; +- buffer[10] = '\0'; ++ if (buffer[11] != '\0') { ++ buffer[11] = ' '; ++ buffer[12] = '\0'; + } + break; + } +diff --git a/darwin/Platform.c b/darwin/Platform.c +index 1dce8b6..d603fd2 100644 +--- a/darwin/Platform.c ++++ b/darwin/Platform.c +@@ -93,7 +93,7 @@ ProcessFieldData Process_fields[] = { + [ST_UID] = { .name = "ST_UID", .title = " UID ", .description = "User ID of the process owner", .flags = 0, }, + [PERCENT_CPU] = { .name = "PERCENT_CPU", .title = "CPU% ", .description = "Percentage of the CPU time the process used in the last sampling", .flags = 0, }, + [PERCENT_MEM] = { .name = "PERCENT_MEM", .title = "MEM% ", .description = "Percentage of the memory the process is using, based on resident memory size", .flags = 0, }, +- [USER] = { .name = "USER", .title = "USER ", .description = "Username of the process owner (or user ID if name cannot be determined)", .flags = 0, }, ++ [USER] = { .name = "USER", .title = "USER ", .description = "Username of the process owner (or user ID if name cannot be determined)", .flags = 0, }, + [TIME] = { .name = "TIME", .title = " TIME+ ", .description = "Total time the process has spent in user and system time", .flags = 0, }, + [NLWP] = { .name = "NLWP", .title = "NLWP ", .description = "Number of threads in the process", .flags = 0, }, + [TGID] = { .name = "TGID", .title = " TGID ", .description = "Thread group ID (i.e. process ID)", .flags = 0, }, +diff --git a/dragonflybsd/DragonFlyBSDProcess.c b/dragonflybsd/DragonFlyBSDProcess.c +index dade106..19d075d 100644 +--- a/dragonflybsd/DragonFlyBSDProcess.c ++++ b/dragonflybsd/DragonFlyBSDProcess.c +@@ -77,7 +77,7 @@ ProcessFieldData Process_fields[] = { + [ST_UID] = { .name = "ST_UID", .title = " UID ", .description = "User ID of the process owner", .flags = 0, }, + [PERCENT_CPU] = { .name = "PERCENT_CPU", .title = "CPU% ", .description = "Percentage of the CPU time the process used in the last sampling", .flags = 0, }, + [PERCENT_MEM] = { .name = "PERCENT_MEM", .title = "MEM% ", .description = "Percentage of the memory the process is using, based on resident memory size", .flags = 0, }, +- [USER] = { .name = "USER", .title = "USER ", .description = "Username of the process owner (or user ID if name cannot be determined)", .flags = 0, }, ++ [USER] = { .name = "USER", .title = "USER ", .description = "Username of the process owner (or user ID if name cannot be determined)", .flags = 0, }, + [TIME] = { .name = "TIME", .title = " TIME+ ", .description = "Total time the process has spent in user and system time", .flags = 0, }, + [NLWP] = { .name = "NLWP", .title = "NLWP ", .description = "Number of threads in the process", .flags = 0, }, + [TGID] = { .name = "TGID", .title = " TGID ", .description = "Thread group ID (i.e. process ID)", .flags = 0, }, +diff --git a/freebsd/FreeBSDProcess.c b/freebsd/FreeBSDProcess.c +index f81fadf..1ed6c2a 100644 +--- a/freebsd/FreeBSDProcess.c ++++ b/freebsd/FreeBSDProcess.c +@@ -76,7 +76,7 @@ ProcessFieldData Process_fields[] = { + [ST_UID] = { .name = "ST_UID", .title = " UID ", .description = "User ID of the process owner", .flags = 0, }, + [PERCENT_CPU] = { .name = "PERCENT_CPU", .title = "CPU% ", .description = "Percentage of the CPU time the process used in the last sampling", .flags = 0, }, + [PERCENT_MEM] = { .name = "PERCENT_MEM", .title = "MEM% ", .description = "Percentage of the memory the process is using, based on resident memory size", .flags = 0, }, +- [USER] = { .name = "USER", .title = "USER ", .description = "Username of the process owner (or user ID if name cannot be determined)", .flags = 0, }, ++ [USER] = { .name = "USER", .title = "USER ", .description = "Username of the process owner (or user ID if name cannot be determined)", .flags = 0, }, + [TIME] = { .name = "TIME", .title = " TIME+ ", .description = "Total time the process has spent in user and system time", .flags = 0, }, + [NLWP] = { .name = "NLWP", .title = "NLWP ", .description = "Number of threads in the process", .flags = 0, }, + [TGID] = { .name = "TGID", .title = " TGID ", .description = "Thread group ID (i.e. process ID)", .flags = 0, }, +diff --git a/linux/LinuxProcess.c b/linux/LinuxProcess.c +index 5f69707..1288155 100644 +--- a/linux/LinuxProcess.c ++++ b/linux/LinuxProcess.c +@@ -206,7 +206,7 @@ ProcessFieldData Process_fields[] = { + [ST_UID] = { .name = "ST_UID", .title = " UID ", .description = "User ID of the process owner", .flags = 0, }, + [PERCENT_CPU] = { .name = "PERCENT_CPU", .title = "CPU% ", .description = "Percentage of the CPU time the process used in the last sampling", .flags = 0, }, + [PERCENT_MEM] = { .name = "PERCENT_MEM", .title = "MEM% ", .description = "Percentage of the memory the process is using, based on resident memory size", .flags = 0, }, +- [USER] = { .name = "USER", .title = "USER ", .description = "Username of the process owner (or user ID if name cannot be determined)", .flags = 0, }, ++ [USER] = { .name = "USER", .title = "USER ", .description = "Username of the process owner (or user ID if name cannot be determined)", .flags = 0, }, + [TIME] = { .name = "TIME", .title = " TIME+ ", .description = "Total time the process has spent in user and system time", .flags = 0, }, + [NLWP] = { .name = "NLWP", .title = "NLWP ", .description = "Number of threads in the process", .flags = 0, }, + [TGID] = { .name = "TGID", .title = " TGID ", .description = "Thread group ID (i.e. process ID)", .flags = 0, }, +diff --git a/openbsd/OpenBSDProcess.c b/openbsd/OpenBSDProcess.c +index 70f9653..ed90cf2 100644 +--- a/openbsd/OpenBSDProcess.c ++++ b/openbsd/OpenBSDProcess.c +@@ -150,7 +150,7 @@ ProcessFieldData Process_fields[] = { + .flags = 0, }, + [USER] = { + .name = "USER", +- .title = "USER ", ++ .title = "USER ", + .description = "Username of the process owner (or user ID if name cannot be determined)", + .flags = 0, }, + [TIME] = { +diff --git a/solaris/SolarisProcess.c b/solaris/SolarisProcess.c +index 31f488e..7452e94 100644 +--- a/solaris/SolarisProcess.c ++++ b/solaris/SolarisProcess.c +@@ -93,7 +93,7 @@ ProcessFieldData Process_fields[] = { + [ST_UID] = { .name = "ST_UID", .title = " UID ", .description = "User ID of the process owner", .flags = 0, }, + [PERCENT_CPU] = { .name = "PERCENT_CPU", .title = "CPU% ", .description = "Percentage of the CPU time the process used in the last sampling", .flags = 0, }, + [PERCENT_MEM] = { .name = "PERCENT_MEM", .title = "MEM% ", .description = "Percentage of the memory the process is using, based on resident memory size", .flags = 0, }, +- [USER] = { .name = "USER", .title = "USER ", .description = "Username of the process owner (or user ID if name cannot be determined)", .flags = 0, }, ++ [USER] = { .name = "USER", .title = "USER ", .description = "Username of the process owner (or user ID if name cannot be determined)", .flags = 0, }, + [TIME] = { .name = "TIME", .title = " TIME+ ", .description = "Total time the process has spent in user and system time", .flags = 0, }, + [NLWP] = { .name = "NLWP", .title = "NLWP ", .description = "Number of threads in the process", .flags = 0, }, + [TGID] = { .name = "TGID", .title = " TGID ", .description = "Thread group ID (i.e. process ID)", .flags = 0, }, +diff --git a/unsupported/Platform.c b/unsupported/Platform.c +index ba84419..cf5b09d 100644 +--- a/unsupported/Platform.c ++++ b/unsupported/Platform.c +@@ -53,7 +53,7 @@ ProcessFieldData Process_fields[] = { + [ST_UID] = { .name = "ST_UID", .title = " UID ", .description = "User ID of the process owner", .flags = 0, }, + [PERCENT_CPU] = { .name = "PERCENT_CPU", .title = "CPU% ", .description = "Percentage of the CPU time the process used in the last sampling", .flags = 0, }, + [PERCENT_MEM] = { .name = "PERCENT_MEM", .title = "MEM% ", .description = "Percentage of the memory the process is using, based on resident memory size", .flags = 0, }, +- [USER] = { .name = "USER", .title = "USER ", .description = "Username of the process owner (or user ID if name cannot be determined)", .flags = 0, }, ++ [USER] = { .name = "USER", .title = "USER ", .description = "Username of the process owner (or user ID if name cannot be determined)", .flags = 0, }, + [TIME] = { .name = "TIME", .title = " TIME+ ", .description = "Total time the process has spent in user and system time", .flags = 0, }, + [NLWP] = { .name = "NLWP", .title = "NLWP ", .description = "Number of threads in the process", .flags = 0, }, + [TGID] = { .name = "TGID", .title = " TGID ", .description = "Thread group ID (i.e. process ID)", .flags = 0, }, +-- +2.19.2 + + diff --git a/overlays/patches/htop/default.nix b/overlays/patches/htop/default.nix new file mode 100644 index 00000000000..2b785545da8 --- /dev/null +++ b/overlays/patches/htop/default.nix @@ -0,0 +1,19 @@ +/* HTOP CUSTOM COLUMN LENGTHS + * + * My nick (spacekookie) is too long to be displayed + * in an htop column. This custom patches fixes this + * + * (<3) + */ +{ pkgs, ... }: + +pkgs.htop.overrideAttrs ({ src, patches ? [], nativeBuildInputs ? [], ... }: { + src = pkgs.fetchFromGitHub { + repo = "htop"; + owner = "hishamhm"; + rev = "402e46bb82964366746b86d77eb5afa69c279539"; + sha256 = "0akyspxl80h2kgp6nhbhnz9v5265pi6d57i6l90pf50l92z61sw7"; + }; + nativeBuildInputs = nativeBuildInputs ++ [ pkgs.autoreconfHook ]; + patches = patches ++ [ ./0001-htop-untruncated-username.patch ]; +}) diff --git a/overlays/patches/neomutt/1388.patch b/overlays/patches/neomutt/1388.patch new file mode 100644 index 00000000000..581c4e2b4af --- /dev/null +++ b/overlays/patches/neomutt/1388.patch @@ -0,0 +1,29 @@ +From aaee4ae3272416ad0d66a4984f3398552df13cef Mon Sep 17 00:00:00 2001 +From: Alyssa Ross +Date: Sun, 4 Nov 2018 17:01:05 +0000 +Subject: [PATCH] Work around mutt_expando_format buffer overflow + +This doesn't actually fix the overflow, but at least makes it less +likely to be encountered. + +See https://github.com/neomutt/neomutt/issues/1388. +--- + muttlib.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/muttlib.c b/muttlib.c +index 431d759b9..1498c5a45 100644 +--- a/muttlib.c ++++ b/muttlib.c +@@ -773,7 +773,7 @@ void mutt_expando_format(char *buf, size_t buflen, size_t col, int cols, const c + FILE *filter = NULL; + char *recycler = NULL; + +- char src2[STRING]; ++ char src2[LONG_STRING]; + mutt_str_strfcpy(src2, src, mutt_str_strlen(src) + 1); + src = src2; + +-- +2.19.1 + diff --git a/overlays/patches/neomutt/default.nix b/overlays/patches/neomutt/default.nix new file mode 100644 index 00000000000..d4776e49e1c --- /dev/null +++ b/overlays/patches/neomutt/default.nix @@ -0,0 +1,13 @@ +/* LONGER NEOMUTT PARAMETER LISTS PATCH + * + * Because of how my neomutt config handles GPG + * encryption, neomutt needs to be patched to + * allow for a longer argument buffer. + * Luckily someone had already written a patch + * for this, so I didn't have to :) + */ +{ pkgs, ... }: + +pkgs.neomutt.overrideAttrs ({ patches ? [], ... }: { + patches = patches ++ [ ./1388.patch ]; +}) diff --git a/overlays/staging/nodemcu-uploader/default.nix b/overlays/staging/nodemcu-uploader/default.nix new file mode 100644 index 00000000000..43176a9c890 --- /dev/null +++ b/overlays/staging/nodemcu-uploader/default.nix @@ -0,0 +1,23 @@ +{ stdenv, python2, python2Packages, ... }: + +python2.pkgs.buildPythonApplication rec { + pname = "nodemcu-uploader"; + version = "0.4.3"; + + src = python2.pkgs.fetchPypi { + inherit pname version; + sha256 = "13nlc2gr85pw7kcfirzi3k8rqybmdwhsxnndixvayis1fm80bsrf"; + }; + + propagatedBuildInputs = with python2.pkgs; [ pyserial wrapt ]; + + doCheck = false; + + meta = with stdenv.lib; { + description = "Lalalala"; + homepage = https://www.foo.org; + license = licenses.mit; + platforms = platforms.unix; + maintainers = with maintainers; [ spacekookie ]; + }; +} diff --git a/overlays/staging/pleroma/default.nix b/overlays/staging/pleroma/default.nix new file mode 100644 index 00000000000..1e1cc2d58eb --- /dev/null +++ b/overlays/staging/pleroma/default.nix @@ -0,0 +1,25 @@ +{ stdenv, lib, pkgs, fetchFromGitLab, ... }: + +stdenv.mkDerivation rec { + name = "pleroma-${version}"; + version = "0.9.0"; + + src = fetchFromGitLab rec { + domain = "git.pleroma.social"; + owner = "pleroma"; + repo = "pleroma"; + rev = "v${version}"; + sha256 = "1k33h3j67ywrmkrjr1hvb53j3zsvszb4rfraak1vsh7jn4j6a0wl"; + }; + + installPhase = '' + cp -r $src $out + ''; + + meta = with lib; { + description = "A free, federated social networking server built on open protocols"; + license = licenses.agpl3; + maintainers = [ maintainers.spacekookie ]; + platforms = platforms.all; + }; +} -- cgit v1.2.3