• Stars
    star
    153
  • Rank 243,368 (Top 5 %)
  • Language
    Emacs Lisp
  • License
    GNU General Publi...
  • Created almost 11 years ago
  • Updated over 5 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

dependency management system on top of use-package

req-package

https://img.shields.io/badge/license-GPL_3-green.svg http://melpa.org/packages/req-package-badge.svg http://stable.melpa.org/packages/req-package-badge.svg https://travis-ci.org/edvorg/req-package.svg https://coveralls.io/repos/edvorg/req-package/badge.svg?branch=develop&service=github

Description

req-package provides dependency management for use-package. This allows to write simple and modular configs. Migration from use-package is simple and syntax is almost same.

Usage

Load req-package:

(require 'req-package)

(req-package use-package-el-get ;; prepare el-get support for use-package (optional)
  :force t ;; load package immediately, no dependency resolution
  :config
  (add-to-list 'el-get-recipe-path "~/.emacs.d/el-get/el-get/recipes")
  (el-get 'sync)
  (use-package-el-get-setup))

Define required packages with dependencies using :require. Use :force t if you want to avoid dependency management and load right now. Use :el-get t or :el-get package-name if you want to install from el-get (Requires use-package-el-get package setup like described above).

;; init-dired.el

(req-package dired) ;; this form is optional as it doesn't have any configuration

(req-package dired-single
  :require dired ;; depends on dired
  :config (...))

(req-package dired-isearch
  :require dired ;; depends on dired
  :config (...))

;; init-lua.el

(req-package lua-mode
  :config (...))

(req-package flymake-lua
  :require flymake lua-mode
  :config (...))

;; init-flymake.el

(req-package flymake
  :config (...))

(req-package flymake-cursor
  :require flymake
  :config (...))

(req-package flymake-custom
  :require flymake
  :load-path "/path/to/file/directory"
  :config (...))

Solve dependencies, install and load packages in right order:

;; order doesn't matter here
(require 'init-dired)
(require 'init-lua)
(require 'init-flymake)
(req-package-finish)

Logging

You can use req-package--log-open-log to see, what is happening with your configuration. You can choose log level in req-package group by req-package-log-level custom. These log levels are supported: fatal, error, warn, info, debug, trace.

Migrate from use-package

Just replace all (use-package ...) with (req-package [:require DEPS] ...) and add (req-package-finish) at the end of your configuration file. There is a :force keyword which simulates plain old use-package behavior.

Note

More complex req-package usage example can be found at https://github.com/edvorg/emacs-configs.

Use load-dir package to load all *.el files in a dir (e.g ~/.emacs.d/init.d)

Contribute

Please, pull-request your changes to develop branch. Master is used for automatic release package builds by travis-ci.

Changelog

v1.3

v1.2

  • add :el-get keyword

v1.1

  • due to use-package being mature enough drop providers system. please refer to #52 for migration instructions.

v1.0

  • once you called req-package-finish you are able reload package just by reload req-package form
  • proper errors handling. see req-package--log-open-log for messages
  • smart add-hook which invokes function if mode is loaded
  • refactor providers system
  • no need to use progn in :init and :config sections
  • no need to use list literal in :require section
  • :loader keyword now accepts loaders as keywords or as functions. e.g. :el-get, :elpa, :built-in, :path and my-loader-fn
  • req-package-force replaced with :force keyword

v0.9

  • :loader keyword support

v0.8

  • bugfixes

v0.7

  • fixed some issues with packages installation. all packages will be installed at bootstrap time
  • custom package providers support by req-package-providers
  • priority feature for cross provider packages loading. you can choose, what to try first - elpa, el-get, or something else

v0.6

  • el-get support

v0.5

  • Major system refactoring.
  • Fixed bugs with defered loading.
  • Significant performance optimization.
  • max-specpdl-size, max-lisp-eval-depth issues completely solved.
  • Flexible :require keyword parsing.

v0.4.2

  • Bug fixes.

v0.4.1

  • Various tweaks and bug fixes.

v0.4-all-cycles

  • All cycles of your dependencies will be printed now.
  • Also there are more handy log messages and some bug fixes.

v0.3-cycles

  • There are nice error messages about cycled dependencies now.
  • Cycles printed in a way: pkg1 -> [pkg2 -> ...] pkg1.
  • It means there is a cycle around pkg1.

v0.2-auto-fetch

  • There is no need of explicit :ensure in your code now.
  • When you req-package it adds :ensure if package is available in your repos.
  • Also package deps :ensure‘d automatically too.
  • Just write (req-package pkg1 :require pkg2) and all you need will be installed.

More Repositories

1

god-mode

Minor mode for God-like command entering
Emacs Lisp
849
star
2

git-gutter

Emacs port of GitGutter which is Sublime Text Plugin
Emacs Lisp
830
star
3

helm-swoop

Efficiently hopping squeezed lines powered by Emacs helm interface
Emacs Lisp
688
star
4

org-page

[INACTIVE] A static site generator based on Emacs and org mode.
Emacs Lisp
673
star
5

popwin

Popup Window Manager for Emacs
Emacs Lisp
496
star
6

helm-ag

The silver searcher with helm interface
Emacs Lisp
492
star
7

quickrun

Run command quickly. This packages is inspired quickrun.vim
Emacs Lisp
474
star
8

anzu

Emacs Port of anzu.vim
Emacs Lisp
414
star
9

emamux

tmux manipulation from Emacs
Emacs Lisp
265
star
10

ov

Overlay library for Emacs Lisp.
Emacs Lisp
211
star
11

helm-gtags

GNU GLOBAL helm interface
Emacs Lisp
204
star
12

direx

Directory Explorer for GNU Emacs
Emacs Lisp
204
star
13

terraform-mode

Major mode of Terraform configuration file
Emacs Lisp
194
star
14

git-gutter-fringe

Fringe version of git-gutter.el
Emacs Lisp
160
star
15

git-messenger

Emacs Port of git-messenger.vim
Emacs Lisp
146
star
16

go-eldoc

eldoc for go language
Emacs Lisp
128
star
17

libegit2

Emacs bindings for libgit2
C
115
star
18

key-chord

Map pairs of simultaneously pressed keys to commands
Emacs Lisp
108
star
19

yascroll

Yet Another Scroll Bar Mode
Emacs Lisp
104
star
20

zoom-window

Zoom and Unzoom window
Emacs Lisp
102
star
21

company-jedi

Company backend for Python jedi
Emacs Lisp
100
star
22

swoop

Peculiar buffer navigation for Emacs
Emacs Lisp
90
star
23

org-redmine

Redmine tools using Emacs OrgMode
Emacs Lisp
83
star
24

dired-k

Highlighting dired buffer like k
Emacs Lisp
82
star
25

magit-gerrit

Magit plugin for Gerrit Code Review
Emacs Lisp
61
star
26

go-add-tags

Add field tags for struct fields
Emacs Lisp
59
star
27

pkg-info

Provide information about Emacs packages
Emacs Lisp
57
star
28

helm-css-scss

This emacs program makes your CSS/SCSS/LESS coding faster and easier than ever.
Emacs Lisp
54
star
29

smeargle

Highlighting Regions by Last Updated Time
Emacs Lisp
49
star
30

evil-anzu

anzu for Evil
Emacs Lisp
49
star
31

mongo

MongoDB driver for Emacs Lisp
Emacs Lisp
47
star
32

manage-minor-mode

Manage your minor-mode on the dedicated interface buffer. Emacs.
Emacs Lisp
47
star
33

gh-md

Render markdown using the github api
Emacs Lisp
46
star
34

farmhouse-themes

Hand-picked light and dark color theme for Emacs 24+
Emacs Lisp
43
star
35

go-direx

Tree style source code viewer for Go language
Emacs Lisp
40
star
36

undohist

Persistent Undo History for GNU Emacs
Emacs Lisp
40
star
37

helm-themes

Emacs theme selection with helm interface
Emacs Lisp
38
star
38

fontawesome

fontawesome utility
Emacs Lisp
33
star
39

go-impl

impl for Emacs
Emacs Lisp
32
star
40

ansible-doc

Ansible documentation for GNU Emacs
Emacs Lisp
32
star
41

sr-speedbar

Same frame speedbar
Emacs Lisp
31
star
42

fancy-battery

Display battery in Emacs Mode line
Emacs Lisp
31
star
43

cpp-auto-include

Insert and delete C++ header files automatically.
Emacs Lisp
31
star
44

helm-open-github

Utilities for opening github page
Emacs Lisp
29
star
45

ac-etags

etags/ctags completion source for auto-complete
Emacs Lisp
28
star
46

transpose-frame

Transpose windows arrangement in a frame
Emacs Lisp
26
star
47

osx-trash

Make Emacs' delete-by-moving-to-trash do what you expect it to do on OS X.
Emacs Lisp
26
star
48

ac-emoji

auto-complete source of Emoji
Emacs Lisp
25
star
49

ac-ispell

ispell/aspell completion source for auto-complete
Emacs Lisp
25
star
50

applescript-mode

Emacs mode for editing AppleScript
Emacs Lisp
24
star
51

codic

Codic for Emacs
Emacs Lisp
23
star
52

magit-svn

Git-Svn extension for Magit
Emacs Lisp
22
star
53

helm-pydoc

pydoc with helm interface
Emacs Lisp
20
star
54

evil-textobj-line

Evil Line text object
Emacs Lisp
18
star
55

ac-alchemist

auto-complete source of alchemist
Emacs Lisp
18
star
56

sourcemap

Sourmap parser in Emacs Lisp
Emacs Lisp
18
star
57

dart-mode

An Emacs mode for the Dart language
Dart
16
star
58

helm-ack

App::ack with helm interface
Emacs Lisp
13
star
59

helm-perldoc

perlpod with helm interface
Emacs Lisp
12
star
60

reverse-theme

Emacs color theme of reverse(like 'emacs --reverse-video')
Emacs Lisp
12
star
61

helm-github-issues

github issues with helm interface
Emacs Lisp
12
star
62

ac-capf

auto-complete source of completion-at-point
Emacs Lisp
12
star
63

sound-wav

Play wav file
Emacs Lisp
12
star
64

ac-racer

auto-complete source of racer
Emacs Lisp
10
star
65

qt-pro-mode

GNU Emacs major-mode for Qt build-system files
Emacs Lisp
9
star
66

popup-complete

Completion with popup-el
Emacs Lisp
9
star
67

splitjoin

Emacs port of splitjoin.vim
Emacs Lisp
8
star
68

miniedit

Enhanced editing for minibuffer fields
Emacs Lisp
8
star
69

helm-ispell

ispell completion with helm interface
Emacs Lisp
8
star
70

thingopt

Additional features of thingatpt.el
Emacs Lisp
8
star
71

helm-package

Listing ELPA packages with helm interface
Emacs Lisp
7
star
72

magit-p4

Magit plugin integrating git-p4 add-on.
Emacs Lisp
6
star
73

docean

Interact with DigitalOcean from Emacs
Emacs Lisp
6
star
74

pyimpsort

Sort python imports
Python
5
star
75

emamux-ruby-test

Ruby test with emamux
Emacs Lisp
5
star
76

octicons

Emacs octicons utility
Emacs Lisp
5
star
77

oberon

Major mode for editing Oberon/Oberon-2 program texts
Emacs Lisp
5
star
78

dedicated

A very simple minor mode for dedicated buffers
Emacs Lisp
4
star
79

haxe-mode

Major mode for editing Haxe files.
Emacs Lisp
4
star
80

helm-robe

Helm completing function for robe
Emacs Lisp
4
star
81

ert-expectations

The simplest unit test framework in the world
Emacs Lisp
4
star
82

keydef

A simpler way to define keys, with kbd syntax
Emacs Lisp
3
star
83

help-find-org-mode

Advise help functions to find org babel source blocks instead of tangled source
Emacs Lisp
3
star
84

test-more

Emacs Test framework like Perl's Test::More
Emacs Lisp
3
star
85

tree-mode

A mode to manage tree widgets
Emacs Lisp
3
star
86

showtip

Show tip at cursor
Emacs Lisp
3
star
87

import-popwin

Pop up buffer near by import statements with popwin
Emacs Lisp
3
star
88

literate-coffee-mode

Major mode for Literate CoffeeScript
Emacs Lisp
3
star
89

perl-utils

Emacs Perl utilities
Emacs Lisp
2
star
90

ltsv

LTSV for Emacs
Emacs Lisp
2
star
91

later-do

Execute lisp code ... later
Emacs Lisp
2
star
92

findr

Breadth-first file-finding facility for (X)Emacs
Emacs Lisp
2
star
93

org-json

Conversion between org and json
Emacs Lisp
2
star
94

dirtree

Directory tree views
Emacs Lisp
2
star
95

pylint

Minor mode for running `pylint'
Emacs Lisp
2
star
96

jedi-eldoc

Eldoc with emacs-jedi
Emacs Lisp
2
star
97

w32-browser

Run Windows application associated with a file
Emacs Lisp
2
star
98

setnu

Emacs Lisp
1
star
99

oddmuse

Edit pages on an Oddmuse wiki
Emacs Lisp
1
star
100

.github

Talk and learn about the Emacsorphanage
Makefile
1
star