Skip to content

alezost/pathify.el

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

https://img.shields.io/badge/license-GPL_3-orange.svg http://melpa.org/packages/pathify-badge.svg http://stable.melpa.org/packages/pathify-badge.svg

About

So I have ~/bin directory in my PATH environment variable and I often have a need to make a symlink to some script there. And this Emacs package serves this purpose: I press a key (bound to pathify-dired) in a dired buffer and the current file is pathified (i.e., is symlinked into my ~/bin directory).

Installation

Automatic

This package can be installed from MELPA (with M-x package-install or M-x list-packages).

Manual

For the manual installation, clone the repo, add the directory to load-path and add a couple of autoloads:

(add-to-list 'load-path "/path/to/pathify-dir")
(autoload 'pathify "pathify" nil t)
(autoload 'pathify-dired "pathify" nil t)

Usage

Before using, set or customize pathify-directory variable (if you don’t want to use a default “~/bin” value):

(setq pathify-directory "/path/to/my/dir-placed-in-PATH")

Now you may use M-x pathify-dired command in a dired buffer to pathify the marked files (or the current file if nothing is marked). For convenience, you may bind this command to some key in a usual manner, for example:

(eval-after-load 'dired
  '(define-key dired-mode-map "P" 'pathify-dired))

About

Symlink your scripts into a PATH directory

Resources

Stars

Watchers

Forks

Packages

No packages published