Merge pull request #9060 from oxij/emacs-cleanup

Cleanup in emacs-packages

+102 -62
+3 -4
pkgs/applications/editors/emacs-modes/nyan-mode/default.nix
··· 1 - {trivialBuild, lib, fetchFromGitHub}: 1 + {lib, trivialBuild, fetchFromGitHub}: 2 2 3 3 trivialBuild rec { 4 4 pname = "nyan-mode"; ··· 23 23 cp -r mus $out 24 24 ''; 25 25 26 - meta = with lib; { 26 + meta = { 27 27 description = "An analog indicator of the position in the buffer"; 28 - homepage = https://github.com/TeMPOraL/nyan-mode/; 29 - license = licenses.gpl3Plus; 28 + license = lib.licenses.gpl3Plus; 30 29 }; 31 30 }
+4
pkgs/build-support/emacs/generic.nix
··· 16 16 }@args: 17 17 18 18 let 19 + 19 20 defaultMeta = { 20 21 broken = false; 21 22 platforms = emacs.meta.platforms; 23 + } // optionalAttrs ((args.src.meta.homepage or "") != "") { 24 + homepage = args.src.meta.homepage; 22 25 }; 26 + 23 27 in 24 28 25 29 stdenv.mkDerivation ({
+1 -1
pkgs/build-support/emacs/melpa.nix
··· 31 31 targets = concatStringsSep " " (if files == null then fileSpecs else files); 32 32 33 33 defaultMeta = { 34 - homepage = "http://melpa.org/#/${pname}"; 34 + homepage = args.src.meta.homepage or "http://melpa.org/#/${pname}"; 35 35 }; 36 36 37 37 in
+94 -57
pkgs/top-level/emacs-packages.nix
··· 1 1 # package.el-based emacs packages 2 + 3 + ## FOR USERS 2 4 # 3 - ## add this at the start your init.el: 4 - # (require 'package) 5 + # Recommended way: simply use `emacsWithPackages` from 6 + # `all-packages.nix` with the packages you want. 5 7 # 6 - # ;; optional. makes unpure packages archives unavailable 7 - # (setq package-archives nil) 8 - # 9 - # (add-to-list 'package-directory-list "/run/current-system/sw/share/emacs/site-lisp/elpa") 10 - # 11 - # ;; optional. use this if you install emacs packages to user profiles (with nix-env) 12 - # (add-to-list 'package-directory-list "~/.nix-profile/share/emacs/site-lisp/elpa") 8 + # Possible way: use `emacs` from `all-packages.nix`, install 9 + # everything to a system or user profile and then add this at the 10 + # start your `init.el`: 11 + /* 12 + (require 'package) 13 + 14 + ;; optional. makes unpure packages archives unavailable 15 + (setq package-archives nil) 16 + 17 + ;; optional. use this if you install emacs packages to the system profile 18 + (add-to-list 'package-directory-list "/run/current-system/sw/share/emacs/site-lisp/elpa") 19 + 20 + ;; optional. use this if you install emacs packages to user profiles (with nix-env) 21 + (add-to-list 'package-directory-list "~/.nix-profile/share/emacs/site-lisp/elpa") 22 + 23 + (package-initialize) 24 + */ 25 + 26 + ## FOR CONTRIBUTORS 13 27 # 14 - # (package-initialize) 28 + # When adding a new package here please note that 29 + # * lib.licenses are `with`ed on top of the file here 30 + # * both trivialBuild and melpaBuild will automatically derive a 31 + # `meta` with `platforms` and `homepage` set to something you are 32 + # unlikely to want to override for most packages 15 33 16 34 { overrides 17 35 ··· 44 62 sha256 = "0dlrhc1dmzgrjvcnlqvm6clyv0r6zray6qqliqngy14880grghbm"; 45 63 }; 46 64 packageRequires = [ auto-complete haskell-mode ]; 47 - meta = { license = gpl3Plus; }; 65 + meta = { 66 + description = "Haskell code completion for auto-complete Emacs framework"; 67 + license = gpl3Plus; 68 + }; 48 69 }; 49 70 50 71 ace-jump-mode = melpaBuild rec { ··· 72 93 sha256 = "19y5w9m2flp4as54q8yfngrkri3kd7fdha9pf2xjgx6ryflqx61k"; 73 94 }; 74 95 packageRequires = [ dash s ]; 75 - meta = { license = gpl3Plus; }; 96 + meta = { 97 + description = "Search using ag from inside Emacs"; 98 + license = gpl3Plus; 99 + }; 76 100 }; 77 101 78 102 agda2-mode = with external; trivialBuild { ··· 108 132 sha256 = "1vpc3q40m6dcrslki4bg725j4kv6c6xfxwjjl1ilg7la49fwwf26"; 109 133 }; 110 134 packageRequires = [ gntp log4e ]; 111 - meta = { license = gpl2Plus; }; 135 + meta = { 136 + description = "A Growl-like alerts notifier for Emacs"; 137 + license = gpl2Plus; 138 + }; 112 139 }; 113 140 114 141 anzu = melpaBuild rec { ··· 127 154 mode which displays current match and total matches information 128 155 in the mode-line in various search mode. 129 156 ''; 130 - homepage = https://github.com/syohex/emacs-anzu/; 131 157 license = gpl3Plus; 132 158 }; 133 159 }; ··· 164 190 rev = "v${version}"; 165 191 sha256 = "1j6mbvvbnm2m1gpsy9ipxiv76b684nn57yssbqdyiwyy499cma6q"; 166 192 }; 167 - meta = { license = gpl3Plus; }; 193 + meta = { 194 + description = "Asynchronous processing in Emacs"; 195 + license = gpl3Plus; 196 + }; 168 197 }; 169 198 170 199 auctex = melpaBuild rec { ··· 177 206 buildPhase = '' 178 207 cp $src ${pname}-${version}.tar 179 208 ''; 180 - meta = { license = gpl3Plus; }; 209 + meta = { 210 + description = "Extensible package for writing and formatting TeX files in GNU Emacs and XEmacs"; 211 + homepage = https://www.gnu.org/software/auctex/; 212 + license = gpl3Plus; 213 + }; 181 214 }; 182 215 183 216 auto-complete = melpaBuild rec { ··· 194 227 description = "Auto-complete extension for Emacs"; 195 228 homepage = http://cx4a.org/software/auto-complete/; 196 229 license = gpl3Plus; 197 - platforms = lib.platforms.all; 198 230 }; 199 231 }; 200 232 ··· 221 253 sha256 = "187wnqqm5g43cg8b6a9rbd9ncqad5fhjb96wjszbinjh1mjxyh7i"; 222 254 }; 223 255 files = [ "bind-key.el" ]; 224 - meta = { license = gpl3Plus; }; 256 + meta = { 257 + description = "A simple way to manage personal keybindings"; 258 + license = gpl3Plus; 259 + }; 225 260 }; 226 261 227 262 browse-kill-ring = melpaBuild rec { ··· 235 270 }; 236 271 meta = { 237 272 description = "Interactively insert items from Emacs kill-ring"; 238 - homepage = https://github.com/browse-kill-ring/browse-kill-ring/; 239 273 license = gpl2Plus; 240 274 }; 241 275 }; ··· 251 285 }; 252 286 meta = { 253 287 description = "Mouseable text in Emacs"; 254 - homepage = "https://github.com/rolandwalker/button-lock"; 255 288 license = bsd2; 256 289 }; 257 290 }; ··· 267 300 }; 268 301 fileSpecs = [ "emacs/*.el" ]; 269 302 configurePhase = "true"; 270 - meta = { license = gpl2Plus; }; 303 + meta = { 304 + description = "OCaml code editing commands for Emacs"; 305 + license = gpl2Plus; 306 + }; 271 307 }; 272 308 273 309 change-inner = melpaBuild rec { ··· 280 316 sha256 = "1fv8630bqbmfr56zai08f1q4dywksmghhm70084bz4vbs6rzdsbq"; 281 317 }; 282 318 packageRequires = [ expand-region ]; 283 - meta = { license = gpl3Plus; }; 319 + meta = { 320 + description = "Change contents based on semantic units in Emacs"; 321 + license = gpl3Plus; 322 + }; 284 323 }; 285 324 286 325 circe = melpaBuild rec { ··· 294 333 }; 295 334 packageRequires = [ lcs lui ]; 296 335 fileSpecs = [ "lisp/circe*.el" ]; 297 - meta = { license = gpl3Plus; }; 336 + meta = { 337 + description = "IRC client for Emacs"; 338 + license = gpl3Plus; 339 + }; 298 340 }; 299 341 300 342 company = melpaBuild rec { ··· 306 348 rev = version; 307 349 sha256 = "08rrjfp2amgya1hswjz3vd5ja6lg2nfmm7454p0h1naz00hlmmw0"; 308 350 }; 309 - meta = { license = gpl3Plus; }; 351 + meta = { 352 + description = "Modular text completion framework for Emacs"; 353 + license = gpl3Plus; 354 + }; 310 355 }; 311 356 312 357 company-ghc = melpaBuild rec { ··· 334 379 rev = version; 335 380 sha256 = "02gfrcda7gj3j5yx71dz40xylrafl4pcaj7bgfajqi9by0w2nrnx"; 336 381 }; 337 - meta = { license = gpl3Plus; }; 382 + meta = { 383 + description = "A modern list library for Emacs"; 384 + license = gpl3Plus; 385 + }; 338 386 }; 339 387 340 388 deferred = melpaBuild rec { ··· 355 403 The API and implementations were translated from JSDeferred (by cho45) 356 404 and Mochikit.Async (by Bob Ippolito) in JavaScript. 357 405 ''; 358 - homepage = https://github.com/kiwanami/emacs-deferred; 359 406 license = gpl3Plus; 360 407 }; 361 408 }; ··· 369 416 rev = version; 370 417 sha256 = "0hshw7z5f8pqxvgxw74kbj6nvprsgfvy45fl854xarnkvqcara09"; 371 418 }; 372 - meta = { license = gpl3Plus; }; 419 + meta = { 420 + description = "Diminishes the amount of space taken on the mode-line by Emacs minor modes"; 421 + homepage = http://www.eskimo.com/~seldon/; 422 + license = gpl3Plus; 423 + }; 373 424 }; 374 425 375 426 epl = melpaBuild rec { ··· 770 821 }; 771 822 meta = { 772 823 description = "Does what you expected ido-everywhere to do in Emacs"; 773 - homepage = https://github.com/DarwinAwardWinner/ido-ubiquitous/; 774 824 license = gpl3Plus; 775 825 }; 776 826 }; ··· 949 999 }; 950 1000 }; 951 1001 952 - nyan-mode = callPackage ../applications/editors/emacs-modes/nyan-mode {}; 1002 + nyan-mode = callPackage ../applications/editors/emacs-modes/nyan-mode { 1003 + inherit lib; 1004 + }; 953 1005 954 1006 org-plus-contrib = melpaBuild rec { 955 1007 pname = "org-plus-contrib"; ··· 981 1033 Org-trello is an emacs minor mode that extends org-mode with 982 1034 Trello abilities. 983 1035 ''; 984 - homepage = https://org-trello.github.io; 1036 + homepage = https://org-trello.github.io/; 985 1037 license = gpl3Plus; 986 1038 }; 987 1039 }; ··· 1079 1131 sha256 = "0dja4g43zfjbxqvz2cgivgq5sfm6fz1563qgrp4yxknl7bdggb92"; 1080 1132 }; 1081 1133 1082 - meta = with stdenv.lib; { 1134 + files = [ "request.el" ]; 1135 + 1136 + meta = { 1083 1137 description = "Easy HTTP request for Emacs Lisp"; 1084 1138 longDescription = '' 1085 1139 Request.el is a HTTP request library with multiple backends. It supports ··· 1088 1142 Library author can use request.el to avoid imposing external dependencies 1089 1143 such as curl to users while giving richer experience for users who have curl. 1090 1144 ''; 1091 - homepage = https://github.com/tkf/emacs-request; 1092 1145 license = gpl3Plus; 1093 1146 }; 1094 1147 }; 1095 1148 1096 1149 request-deferred = melpaBuild rec { 1097 1150 pname = "request-deferred"; 1098 - version = "0.2.0"; 1099 - 1100 - src = fetchFromGitHub { 1101 - owner = "tkf"; 1102 - repo = "emacs-request"; 1103 - rev = "adf7de452f9914406bfb693541f1d280093c4efd"; 1104 - sha256 = "0dja4g43zfjbxqvz2cgivgq5sfm6fz1563qgrp4yxknl7bdggb92"; 1105 - }; 1106 - 1151 + version = request.version; 1152 + src = request.src; 1107 1153 packageRequires = [ request deferred ]; 1108 - 1109 - meta = with stdenv.lib; { 1110 - description = "Easy HTTP request for Emacs Lisp"; 1111 - longDescription = '' 1112 - Request.el is a HTTP request library with multiple backends. It supports 1113 - url.el which is shipped with Emacs and curl command line program. User 1114 - can use curl when s/he has it, as curl is more reliable than url.el. 1115 - Library author can use request.el to avoid imposing external dependencies 1116 - such as curl to users while giving richer experience for users who have curl. 1117 - ''; 1118 - homepage = https://github.com/tkf/emacs-request; 1119 - license = gpl3Plus; 1120 - }; 1154 + files = [ "request-deferred.el" ]; 1155 + meta = request.meta 1156 + // { description = "${request.meta.description} (deferred)"; }; 1121 1157 }; 1122 1158 1123 1159 rich-minority = melpaBuild rec { ··· 1130 1166 sha256 = "0kvhy4mgs9llihwsb1a9n5a85xzjiyiyawxnz0axy2bvwcxnp20k"; 1131 1167 }; 1132 1168 packageRequires = [ dash ]; 1133 - meta = { license = gpl3Plus; }; 1169 + meta = { 1170 + description = "Hiding and/or highlighting the list of minor modes in the Emacs mode-line."; 1171 + license = gpl3Plus; 1172 + }; 1134 1173 }; 1135 1174 1136 1175 s = melpaBuild rec { ··· 1211 1250 }; 1212 1251 meta = { 1213 1252 description = "M-x enhancement for Emacs build on top of Ido"; 1214 - homepage = https://github.com/nonsequitur/smex/; 1215 1253 license = emacs.meta.license; # should be "same as Emacs" 1216 1254 }; 1217 1255 }; ··· 1224 1262 fileSpecs = [ "elisp/*.el" ]; 1225 1263 1226 1264 meta = { 1227 - homepage = "https://github.com/chrisdone/structured-haskell-mode"; 1228 1265 description = "Structured editing Emacs mode for Haskell"; 1229 1266 license = bsd3; 1230 1267 platforms = external.structured-haskell-mode.meta.platforms;