This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// randomString(length) | |
// -------------------- | |
// | |
// Generates and returns a cryptographically secure | |
// uniform alphanumeric random string. | |
// | |
// Examples: | |
// | |
// randomString(14) // "oXYWpc1vODNR3M" | |
// randomString.hex(8) // "663c722b65943b9b" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(require 'cl-lib) | |
;; Depends on s.el | |
(defun direnv-data (dir) | |
;; TODO: use dir for folder or smart current-project-dir variable | |
(let ((cmd (concat "$SHELL -i -c '" "cd " dir " && direnv export bash'"))) | |
(shell-command-to-string cmd))) | |
;;(direnv-data "~/src/direnv") | |
(defun commands-from-direnv (text) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NEW! you can install via cpan: https://metacpan.org/release/PACMAN/Acme-CatFS-0.001 | |
1. you should install LWP::Simple and Fuse:Simple - use cpan or cpanm | |
2. you should configure the local fuse install to run as root or as common user | |
3. don't forget 'fusermount -u <mountpoint>' after finish the script | |
to install dependencies | |
you can use regular cpan OR cpanminus ( http://search.cpan.org/~miyagawa/App-cpanminus-1.7001/lib/App/cpanminus.pm ) |