npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

yakshave

v0.1.3

Published

A Clojurescript manager for Leiningen projects

Readme

  • yakshave

    #+BEGIN_QUOTE Richter: Die monster. You don’t belong in this world!

    Dracula: It was not by my hand I was once again given flesh. I was brought here by humans who wished to be me tribute!

    Richter: Tribute!? You steal men’s souls, and make them your slaves!

    Dracula: Perhaps the same could be said of all religions…

    Richter: Your words are as empty as your soul! Mankind ill needs a savior such as you!

    Dracula: What is a man? A miserable little pile of secrets. But enough talk… Have at you! #+END_QUOTE

** What is a yakshave? Yakshave is a tool written in Clojurescript (Nodejs) for managing and generating [[https://github.com/technomancy/leiningen][leiningen]] projects. It aims to handle the scripting tasks that leiningen is currently used for and more.

Provided that you have nodejs, you can install yakshave with:

#+BEGIN_SRC sh $ npm install yakshave -g #+END_SRC

The latest version is 0.1.2.

You can also fork it and run:

#+BEGIN_SRC sh $ lein cljsbuild once prod $ npm install -g #+END_SRC

** Why should I yakshave? It's a lot faster - in the initial release:

#+BEGIN_SRC sh $ time yakshave new foobar

yakshave new foobar 0.60s user 0.05s system 96% cpu 0.668 total

$ time lein new bizbar

lein new bizbar 4.07s user 0.10s system 145% cpu 2.877 total

#+END_SRC

Hmm. Like 6 times faster. But remember, those templates are buried deep within the leiningen.jar.

#+BEGIN_SRC sh $ time ys new compojure example !2804 yakshave new compojure example 0.18s user 0.01s system 101% cpu 0.191 total

$ time lein new compojure example2 !2841 lein new compojure example2 4.66s user 0.18s system 120% cpu 4.020 total #+END_SRC

For small templates it's almost 26 times faster! Note that the compojure template refers to this repository: https://github.com/johnwalker/compojure-template

Aliasing yakshave to ys for finger performance is recommended.

#+BEGIN_SRC sh

in .bashrc / .zshrc

alias ys='yakshave' #+END_SRC ** Why shouldn't I yakshave? It's not battle-tested. There are probably a lot of bugs, too. Many lein templates aren't yet compatible with yakshave. [[http://pages.citebite.com/b2x0j8q1megb][You would have to install nodejs.]] ** Complete list of supported tasks #+BEGIN_SRC sh yakshave new template-name? project-name #+END_SRC ** Usage *** new - Generating projects Yakshave templates -- just like leiningen -- are hosted in maven repositories. It is very easy for a leiningen template to be a yakshave template, and vice versa. The difference between the two is that yakshave templates use edn, while leiningen templates are fully programmatic, as they are written in Clojure. Since yakshave is brand new, many lein templates will not work yet. If you're the author of a template and want some help setting it up for yakshave, please open an issue!

One very important difference is that *yakshave doesn't fetch
templates yet.*

#+BEGIN_EXAMPLE
yakshave new foobar
yakshave new app foobar
#+END_EXAMPLE

**** Creating yakshave compatible templates If you squint, yakshave templates look a lot like leiningen ones. Here is what the app template looks like when it's described with yakshave:

 #+BEGIN_SRC clojure

{:renderer "app" :files [["project.clj" "project.clj"] ["README.md" "README.md"] ["doc/intro.md" "intro.md"] [".gitignore" "gitignore"] ["src/{{nested-dirs}}.clj" "core.clj"] ["test/{{nested-dirs}}_test.clj" "test.clj"] ["LICENSE" "LICENSE"] "resources"] :data {:raw-name [:identity] :name [:project-name] :namespace [:sanitize-ns :multi-segment] :nested-dirs [:sanitize-ns :multi-segment :name-to-path] :year [:year]}} #+END_SRC

 The vector is treated as thread-first on the name the user passes
 to yakshave. If a string were passed instead, then that value
 would merely be substituted. For example, in the "template" template:
 #+BEGIN_SRC  clojure

{:renderer "template" :files [["README.md" "README.md"] ["project.clj" "project.clj"] [".gitignore" "gitignore"] ["src/leiningen/new/{{sanitized}}.clj" "temp.clj"] ["resources/leiningen/new/{{sanitized}}/foo.clj" "foo.clj"] ["LICENSE" "LICENSE"]] :data {:name [:identity] :sanitized [:sanitize] :placeholder "{{:sanitized}}" :year [:year]}} #+END_SRC

 The valid keys are

 #+BEGIN_SRC clojure

:year :identity :sanitize-ns :sanitize :multi-segment :name-to-path :group-name :project-name :unprefix #+END_SRC

 which correspond directly to the built-in leiningen ones. Two new
 keys are :identity and :unprefix. You already know what :identity
 does, and you don't care about :unprefix.

**** List of yakshave compatible templates The built-in leiningen templates:

 + app
 + default
 + template
 + plugin

   The compojure fork: https://github.com/johnwalker/compojure-template

**** Template wishlist These are some high priority templates for yakshave compatibility.

 + cljs-start
 + compojure
 + mies
 + mies-node
 + reloaded

** Contributing Contributors are wanted very badly. There are many ways to help out - porting lein-templates to yakshave, general refactoring, writing documentation, blogging about yakshave and contributing criticism are all great help.

Outside of yakshave itself, these are extremely critical:

  • [[https://github.com/xsc/rewrite-clj/issues/4][porting rewrite-clj to cljs]]
  • contributing to [[https://github.com/clojure/core.match][core.match]], [[https://github.com/clojure/clojurescript][clojurescript]], [[https://github.com/cthackers/adm-zip][adm-zip]] or [[https://github.com/janl/mustache.js][mustache.js]]

** Discussion

  • [[https://groups.google.com/forum/#!topic/clojure/2XjEn5aeoQM][Initial Google groups discussion]] ** License Copyright © 2014 John Walker and contributors

Distributed under the Eclipse Public License version 1.0, the same as Clojure.