Create front end projects from templates, add dependencies, and automate the resulting projects

Overview

volo

Create browser-based, front-end projects from project templates, and add dependencies by fetching them from GitHub. Once your project is set up, automate common tasks.

volo is dependency manager and project creation tool that favors GitHub for the package repository.

At its heart, volo is a generic command runner -- you can create new commands for volo, and you can use commands others have created.

By default, volo knows how to:

Prerequisites

  • Node 0.6.5 or later installed.

If you are using Ubuntu, then you may need to apt-get install nodejs-legacy too.

Install

volo requires Node to run. Node includes npm, a package manager for node code. To install volo:

npm install -g volo

If you get an error when running that command, and it contains this line somewhere in it:

npm ERR! Please try running this command again as root/Administrator.

You will need to run the install via sudo:

sudo npm install -g volo

Usage

volo can use GitHub to retrieve code, so one of the core concepts when using it is understanding user/repo for archive names. See the add doc for more info on the types of archive names to use.

AMD project example

To set up an AMD/RequireJS-based project called fast that uses AMD versions of Backbone, jQuery and underscore:

> volo create fast (uses [volojs/create-template](https://github.com/volojs/create-template) for project template)
> cd fast
> volo add jquery (uses jquery/jquery as the repo)
> volo add underscore (uses amdjs/underscore as repo since an AMD project)
> volo add backbone (uses amdjs/backbone as repo since an AMD project)

Then modify www/js/app.js to require the modules you need and add your app logic.

The above example uses the amdjs/underscore and amdjs/backbone versions of those libraries, which include integrated AMD support.

Browser globals project example

To set up an HTML5 Boilerplate project that does not use AMD/RequireJS, but does use documentcloud repos of Backbone and Underscore (the Boilerplate already has jQuery):

> volo create html5fast html5-boilerplate (pulls down latest tag of that repo)
> cd html5fast
> volo add underscore (uses documentcloud/underscore as repo)
> volo add backbone (uses documentcloud/backbone as repo)

Updating a previously added library

There is no "update" command in Volo. However, updating a library is simple:

> volo add -f underscore

This will delete your local copy of underscore and then re-add underscore.

Library Best Practices

To work well with volo, here are some tips on how to structure your library code:

Details

Engage

Comments
  • New command: serve

    New command: serve

    Does it make sense to have a "serve" command that can start up a static web server for the directory?

    Probably means shipping something like node-static or some other lib. Are licenses compatible? There is a pretty easy python one-liner floating around, maybe just suggest using that instead.

    opened by jrburke 10
  • Node 0.8.22: Unable to find end of central directory record

    Node 0.8.22: Unable to find end of central directory record

    This doesn't happen every time, but often enough.

    When running volo add on travis-ci with node 0.8.22, I often get the message ERROR: Error: Unable to find end of central directory record

    See https://travis-ci.org/iceddev/frozen/jobs/6893229 for an example.

    I have tried modifying my repo in many ways to solve this problem but it seems to be a problem with the zip files. Not sure if something in volo is changing them or the Github API has changed or is being flakey.

    opened by phated 9
  • Package.json checking

    Package.json checking

    I have an application folder structure looking like:

    -package.json -app.js -node_modules -www --js ---require.js ---jquery.js

    If I am in the "www/js" folder and use "volo add", it creates a new package.json in the www/js folder.

    Ideally, volo could check down all the folders until it finds the first package.json. If that package.json references the current folder as a baseUrl, it could use that package.json to ammend to?

    opened by guybedford 9
  • Is there a way to `volo add` a subdirectory with the source files?

    Is there a way to `volo add` a subdirectory with the source files?

    When creating a library with several modules (and one main module), it feels strange having to keep all the source files at the root directory. I would prefer the following structure where all javascript source files are in a subdirectory rather than at the root of the project.

      # The repo of the lib
      lib
          main.js
          helper.js
      tests
          main_test.js
      buster.js
      README
      volofile
    

    When doing volo add mylib I would like to install the lib in the following way

    # A project consuming mylib
    lib
        mylib
            main.js
            helper.js
        mylib.js # adapter
    

    This would allow doing

    require("mylib");
    require("mylib/helper");
    

    Currently I would have to do

    require("mylib");
    require("mylib/lib/helper");
    

    which makes reusing the submodules of mylib more difficult.

    I wonder how I should go about this. To sum up, currently the options are

    1. Keep all source files in the root file as recommended in the wiki.
    2. Keep all source files in a subfolder, but then submodules of the library become difficult to reuse
    3. Keep all source files in a subfolder and after volo adding, create add paths: { "mylib": "lib/mylib/lib" } to the config which is not as nice as having everything working out of the box.
    opened by KidkArolis 8
  • Allow user to resolve version conflicts

    Allow user to resolve version conflicts

    Right now version conflicts are handled by "first one encountered wins", which is fine enough for small projects. However, it would be nicer if the full dependency tree is scanned, and then if there is a version conflict, ask the user which one they want to install.

    opened by jrburke 7
  • css files, images, etc.

    css files, images, etc.

    Say I want to use chosen.js in my project. If I do "volo add chosen" (and if there is an override package.json configured in volo repo), then volo will only install a single javascript file and remove everything else. I would like to preserve the images and css files and @import them in my main.css file of the project. I'm not sure what happens if you then include a library (with css file) that uses a library (with css file) that uses chosen and imports it's css. Do those css imports still resolve correctly. What css files do I now include in my toplevel project. On one hand it feels that this might be better left completely separate from the javascript stuff, but on the other hand it would be nice that when I update to the latest chosen.js version, the css and images are kept up to date as well.

    opened by KidkArolis 7
  • Windows support

    Windows support

    Work it out. Some things in particular:

    • Right now tar -z and rm are used via child_process. How does that work in Windows? Show zip files be used instead? Is there a reliable zip utility that can be used in Node, something that is not a binary component that needs to be built to ship volo?
    • How would symlinks work?
    opened by jrburke 7
  • [/usr/bin/env: node] Error running volo

    [/usr/bin/env: node] Error running volo

    HI, I had a problem to run volo after installing nodejs and volo on my ubuntu gnome shell distr :

    /usr/bin/env: node: No such file or directory

    /usr/bin/env: node: Aucun fichier ou dossier de ce type

    It was hard to find how to fix so I put it here. I had to

    apt-get install nodejs-legacy

    opened by alain-andre 6
  • Volo fails when installing from a URL that issues a 301 HTTP status

    Volo fails when installing from a URL that issues a 301 HTTP status

    ERROR: Error: Download failed, HTTP code: 301:

    If I specify the dependency as:

    http://github.mycompany.com/project/foo/raw/master/foo.js

    Depending on how things are configured, you may be redirected to:

    https://github.mycompany.com/project/foo/raw/master/foo.js (notice the https)

    Volo treats this 301 redirect as an error.

    One can work around this by updating the URL; however, I wouldn't expect a 301 to cause an error.

    opened by wilmoore 6
  • Download speed question

    Download speed question

    I've got a project with 16 dependencies and each repo download takes about 8 seconds to complete (I'm in South Africa, we're not renowned for our fast internet connections). What's interesting is that when I load the URLs directly in the browser, it only takes me about 2 seconds to load that same URL. I know Volo needs to do a repo search and could also be checking the amd-repo list, but I'm still not entirely sure how that is all filling up 8 seconds. Just wondering if there's any scope for speed improvements, because I think it's an important factor for adoption as well.

    opened by guybedford 6
  • Enable debugging using node-inspector

    Enable debugging using node-inspector

    It's sometimes very hard to figure out what's wrong with a volofile, and the ability to hook up a debugger like node-inspector would be immensely useful. However, adding --debug or --debug-brk when running volo seems to do nothing.

    Is there a way to do this currently, that I'm unaware of?

    opened by mstade 6
  • docs: Fix a few typos

    docs: Fix a few typos

    There are small typos in:

    • tests/commands/create/support/addOnCreate/js/jquery.js
    • tests/doh/_browserRunner.js

    Fixes:

    • Should read insignificant rather than insignifant.
    • Should read amenable rather than ammenable.

    Semi-automated pull request generated by https://github.com/timgates42/meticulous/blob/master/docs/NOTE.md

    opened by timgates42 0
  • Bump shell-quote from 0.0.1 to 1.7.2

    Bump shell-quote from 0.0.1 to 1.7.2

    Bumps shell-quote from 0.0.1 to 1.7.2.

    Release notes

    Sourced from shell-quote's releases.

    v1.7.2

    • Fix a regression introduced in 1.6.3. This reverts the Windows path quoting fix. (144e1c2)

    v1.7.1

    • Fix $ being removed when not part of an environment variable name. (@​Adman in #32)

    v1.7.0

    • Add support for parsing >> and >& redirection operators. (@​forivall in #16)
    • Add support for parsing <( process substitution operator. (@​cuonglm in #15)

    v1.6.3

    • Fix Windows path quoting problems. (@​dy in #34)

    v1.6.2

    • Remove dependencies in favour of native methods. (@​zertosh in #21)
    Changelog

    Sourced from shell-quote's changelog.

    1.7.2

    • Fix a regression introduced in 1.6.3. This reverts the Windows path quoting fix. (144e1c2)

    1.7.1

    • Fix $ being removed when not part of an environment variable name. (@​Adman in #32)

    1.7.0

    • Add support for parsing >> and >& redirection operators. (@​forivall in #16)
    • Add support for parsing <( process substitution operator. (@​cuonglm in #15)

    1.6.3

    • Fix Windows path quoting problems. (@​dy in #34)

    1.6.2

    • Remove dependencies in favour of native methods. (@​zertosh in #21)
    Commits
    Maintainer changes

    This version was pushed to npm by goto-bus-stop, a new releaser for shell-quote since your current version.


    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot ignore this [patch|minor|major] version will close this PR and stop Dependabot creating any more for this minor/major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

    dependencies 
    opened by dependabot[bot] 0
  • Limit Number of Requests

    Limit Number of Requests

    I recently had an issue during our build process, volo was getting stuck on:

    volo add -f -nostamp jquery/qunit/v1.14.0#. <-- Endless loop, eventually exceeds rate_limit

    Realized that it's making tons of requests, blowing through my rate limit within a minute or so. The fix ended up being jquery --> qunitjs.

    volo add -f -nostamp qunitjs/qunit/v1.14.0#. <-- This works fine, 1 request

    But I was wondering if it's a bug that it doesn't recognize that the Url is broken, or if there is an option for limiting the number of requests before it will move on/throw error.

    opened by thostetler 0
  • AWS download URLs need extra handling

    AWS download URLs need extra handling

    Looks like AWS wants something fancier done for downloading files from them.

    Test:

    volo add https://github.com/gaye/dav/releases/download/v1.0.3/dav.zip#dav.js

    <?xml version="1.0" encoding="UTF-8"?>
    <Error><Code>AuthorizationQueryParametersError</Code><Message>Query-string authentication version 4 requires the X-Amz-Algorithm, X-Amz-Credential, X-Amz-Signature, X-Amz-Date, X-Amz-SignedHeaders, and X-Amz-Expires parameters.</Message>
    <RequestId>80D47BFAAC204179</RequestId>
    <HostId>0HariKX8ScYk17bnjlLAZNTy3qgstjggzWTYpkh2zxYuudRhBKxn+fBCE7z/bkTFc7B9H94tD/s=</HostId>
    </Error>
    

    Trying to use curl for the same action also gets the same error.

    opened by jrburke 0
  • volo add with amd does not save amd for future reinstall

    volo add with amd does not save amd for future reinstall

    To reproduce, run:

    volo add -amd https://ajax.googleapis.com/ajax/libs/angularjs/1.3.0-rc.3/angular.js depends=jquery=jQuery exports=angular
    

    Contents of package.json:

    {
      "volo": {
        "dependencies": {
          "angular": "https://ajax.googleapis.com/ajax/libs/angularjs/1.3.0-rc.3/angular.js"
        }
      }
    }
    

    Expected behaviour:

    rm angular.js
    volo install
    # angular.js should be amdified
    

    Thanks for the great tool that is volo!

    opened by Rush 4
  • Consider a volo.includes or volo.files

    Consider a volo.includes or volo.files

    As opposed to excludes, the opposite. npm has a files which allows only keeping explicit files, in a nested directory search, which is a bit different than a pure opposite of volo.excludes, which only goes by top level entries. Marking for 0.3.2, but may get pushed for semver reasons, if 0.3.2 does not turn into an 0.4.0.

    opened by jrburke 0
The 1.x line is frozen - features and bugfixes now happen on https://github.com/yarnpkg/berry

Fast, reliable, and secure dependency management. Fast: Yarn caches every package it has downloaded, so it never needs to download the same package ag

Yarn 41k Jan 5, 2023
frontend package manager and build tool for modular web applications

THIS PROJECT IS DEPRECATED Component is not maintained anymore. See here #639 for more information. You can still use the component registry on compon

Component 4.6k Dec 30, 2022
JavaScript package manager - using a browser-focused and RequireJS compatible repository

****NOTE: this project is no longer active and not recommended for use. It is left here for reference. **** Jam was created at a time before Bower and

Caolan McMahon 1.5k Dec 10, 2022
⚡️The Fullstack React Framework — built on Next.js

The Fullstack React Framework "Zero-API" Data Layer — Built on Next.js — Inspired by Ruby on Rails Read the Documentation “Zero-API” data layer lets y

⚡️Blitz 12.5k Jan 4, 2023
A Node.js tool to automate end-to-end web testing.

A Node.js tool to automate end-to-end web testing. Write tests in JS or TypeScript, run them and view results. Homepage • Documentation • FAQ • Suppor

Developer Express Inc. 9.5k Jan 9, 2023
It consists of a recreation of Twitter, to put into practice both Front-end and Back-end knowledge by implementing the MERN Stack together with other technologies to add more value to the project.

Twitter-Clone_Back-end ✨ Demo. ?? About the project. ?? Descriptions. It consists of a recreation of Twitter, to put into practice knowledge of both F

Mario Quirós Luna 5 Apr 12, 2022
It consists of a recreation of Twitter, to put into practice knowledge of both Front-end and Back-end implementing the MERN Stack along with other technologies to add more value to the project.

Twitter-Clone_Front-end ✨ Demo. Login Home Profile Message Notifications Deployed in: https://twitter-clone-front-end.vercel.app/ ?? About the project

Mario Quirós Luna 5 Jun 26, 2022
This template is designed for compiling Rust libraries into WebAssembly and publishing the resulting package to NPM.

This template is designed for compiling Rust libraries into WebAssembly and publishing the resulting package to NPM.

Keith 2 Jul 5, 2022
Demo showcasing information leaks resulting from an IndexedDB same-origin policy violation in WebKit.

Safari 15 IndexedDB Leaks Description This demo showcases information leaks resulting from an IndexedDB same-origin policy violation in WebKit (a brow

FingerprintJS 101 Nov 5, 2022
📡 Encrypt and authenticate DevTools to use it securely remotely. Add HTTPS, and authentication to --remote-debugging-port to debug, inspect and automate from anywhere and collaborate securely on bugs.

?? Encrypt and authenticate DevTools to use it securely remotely. Add HTTPS, and authentication to --remote-debugging-port to debug, inspect and automate from anywhere and collaborate securely on bugs.

Cris 9 May 5, 2022
📡 Encrypt and authenticate DevTools to use it securely remotely. Add HTTPS, and authentication to --remote-debugging-port to debug, inspect and automate from anywhere and collaborate securely on bugs.

?? Encrypt and authenticate DevTools to use it securely remotely. Add HTTPS, and authentication to --remote-debugging-port to debug, inspect and automate from anywhere and collaborate securely on bugs.

Cris 9 May 5, 2022
This project was developed to practice Front-end and Back-end comunication, data formatting, http requests GET, POST, DELETE, form validation, it also consumes a rest API

React Application ?? Demonstration of the application | Features | Technologies used | Application installation ?? Demonstration of the application Ap

Victor Lira 36 May 17, 2022
Personal Blog - a project developed with Angular for the front-end interface and Wordpress for the back-end API served with Docker containers

PersonalBlog This project was generated with Angular CLI version 13.0.1. Front-end Interface Development server Run ng serve or ng serve --configurati

null 9 Oct 5, 2022
This is a template project demonstrating how the MERN stack(Mongo, Express, React, Node) can be used, here we have the back end implementation and there is the React implementation as the front end

Versão em português MERN stack This is a template project demonstrating how the MERN stack(Mongo, Express, React, Node) can be used, here we have the

Douglas Samuel Gonçalves 2 Jan 22, 2022
Web-Technology with Aj Zero Coding. In this tutorial we learn front-end and back-end development.

Installation through NPM: The jQWidgets framework is available as NPM package: jQuery, Javascript, Angular, Vue, React, Web Components: https://www

Ajay Dhangar 3 Nov 19, 2022
Pass trust from a front-end Algorand WalletConnect session, to a back-end web service

AlgoAuth Authenticate to a website using only your Algorand wallet Pass trust from a front-end Algorand WalletConnect session, to a back-end web servi

Nullable Labs 16 Dec 15, 2022
A super generic Lua web engine. Uses Lua for front-end, JavaScript for back-end, implemented in HTML.

A super generic Lua web engine. Uses Lua for front-end, JavaScript for back-end, implemented in HTML. This project is still in HEAVY development and w

Hunter 2 Jan 31, 2022
Automate adding issues and pull requests to GitHub projects (beta)

actions/add-to-project Use this action to automatically add the current issue or pull request to a GitHub project. Note that this is for GitHub projec

GitHub Actions 293 Jan 3, 2023
GitHub action to automate managing repositories with labels, milestones and projects.

triagecat GitHub action to automate managing repositories with labels, milestones and projects. Link issues and PRs labels. Add issues and PRs to a pr

Oliver Wilkes 6 Jun 14, 2022
Bookstore CMS React Front-End to display a list of books, categorize it, add and remove books and update your reading progress

Bookstore REACT app to manage your books Build an app to display a list of books, categorize it, add and remove books and update your reading progress

Eapen Zacharias 3 Aug 19, 2022