How to setup a private bower repository with SVN support

Bower, NPM
This tutorial shows you how to setup a private bower repository with SVN support. We will use the nodejs package private-bower to achieve this goal. Requirements: A server which has nodejs installed. Of course you can use your development machine for initial testing and "one-person" projects. Steps: Setup the server Configure your bower package to publish to the private repository Configure bower in your consuming project(s) to fetch packages through private repository 1. Setup the server On the server create a folder to install private-bower. In this folder execute the command: [crayon-5b74054b4eff6820031926/] Once the package is installed, you can start the repository: [crayon-5b74054b4f004495966068/] Your server is ready! You can access the web UI on http://localhost:5678. At this point we use the default configuration of the bower repository server. There are…
Read More

grunt: Warning: Task “ngAnnotate” not found. Use –force to continue.

Grunt, NPM
"Warning: Task "ngAnnotate" not found. Use --force to continue." during "grunt dist" or "grunt build" If you get this warning when you execute a grunt build or grunt distcommand you could check if the grunt-ng-annotate package is installed locally and added to your package dev dependencies. An easier way is just to execute the install command again. Go to the project root folder (where the gruntfile.js is located) and execute: [crayon-5b74054b5038b137832659/] - Be sure not to add the -g argument as this would install the package globally instead of locally. - Be sure to add the --save-dev argument as this will add the package to the devDependencies list in the package.json file of your project. This is required for the grunt build task to work. Now retry the grunt build…
Read More

How to check if npm package was installed globally or locally

NPM
This code snippet shows you how to check if npm package was installed globally or locally. To check if a specific package is installed globally execute: [crayon-5b74054b5072b393434171/] Let's take package "grunt" as an example. If it is installed globally, you should see something like this [crayon-5b74054b50732351493201/] If it is not installed globally, you should see something like this [crayon-5b74054b50735531447960/] To check if a specific package is installed locally you can execute the same commands as above but without the -g parameter.
Read More

NPM check the version of an installed package

NPM
This snippet shows you how to check the version of an installed package with NPM [crayon-5b74054b50aea776909074/] This gives you the number of the currently installed version. Example: [crayon-5b74054b50af1304049158/] The package version is only one of the many available properties that can be queried. The npm view syntax is as follows: [crayon-5b74054b50af4458236102/] Some examples: [crayon-5b74054b50b03327933687/]
Read More

npm WARN deprecated ngmin: use ng-annotate instead

AngularJS, NPM
This article describes how to replace the deprecated ngmin with ng-annotate. ngmin used to be a popular AngularJS application pre-minifier.  Though it is now deprecated. message: npm WARN deprecated ngmin@0.5.0: use ng-annotate instead cause: ngmin is no longer maintained, you should use ng-annotate instead. solution: Migrate from ngmin to ng-annotate: ng-annotate -a is similar to ngmin (use stdin and stdout). ng-annotate -a in.js -o out.js is similar to ngmin in.js out.js. - Installation: [crayon-5b74054b50f18733940210/] Grunt users can migrate easily by installing grunt-ng-annotate and replacing ngmin with ngAnnotate in their Gruntfile. - Install grunt-ng-annotate:     Start a shell at the folder where gruntfile.js is located and execute: [crayon-5b74054b50f1f075822763/] - Modify your gruntfile.js: replace any occurrence of ngmin in ngAnnotate: [crayon-5b74054b50f22835937112/] Done!    
Read More

How to enable the web interface in Sinopia

NPM, Web
This tutorial will show you how to enable the web interface in Sinopia. The web interface in Sinopia is a work-in-progress , though it is already usable. In a previous tutorial we saw how to setup a private NMP repository with Sinopia. Now we will see how to enable the web interface in Sinopia. Try accessing the web interface After installing the Sinopia server we can immediately access the web interface. If you navigate to http://localhost:4873/ you will see a message like: [crayon-5b74054b51345209244170/] Enable the web interface In order to enable the web interface we need to change the following setting to the config.yaml file which is located in the root of the Sinopia installation. Scroll to a section named the web and set enabled to true. [crayon-5b74054b5134c822277544/] After you…
Read More