How to stay on top of nightlies?

I’ve got a bash script that I use to download nightly versions of ionic files into my project, but it occurs to me that new dependencies could be introduced or that maybe I’m not updating everything. So here’s my bash script. Am I missing anything? Would you add more? Do something differently?

wget http://code.ionicframework.com/nightly/css/ionic.css -O lib/css/ionic.nightly.css
wget http://code.ionicframework.com/nightly/js/ionic.js -O lib/js/ionic.nightly.js
wget http://code.ionicframework.com/nightly/js/angular/angular.min.js -O lib/js/angular/angular.nightly.js
wget http://code.ionicframework.com/nightly/js/angular/angular-animate.min.js -O lib/js/angular/angular-animate.nightly.js
wget http://code.ionicframework.com/nightly/js/angular/angular-sanitize.min.js -O lib/js/angular/angular-sanitize.nightly.js
wget http://code.ionicframework.com/nightly/js/angular-ui/angular-ui-router.min.js -O lib/js/angular-ui/angular-ui-router.nightly.js
wget http://code.ionicframework.com/nightly/js/ionic-angular.js -O lib/js/ionic-angular.nightly.js

You’re introducing yourself to a world of hurt by riding the bleeding-edge, but as long as you’re just doing dev work and are okay with your project being in some state of broken every morning, you can start by including the new Ionic bundle instead of the individual dependencies:

<!-- ionic.bundle.js is a concatenation of:
        * ionic.js, angular.js, angular-animate.js,
        * angular-ui-router.js, and ionic-angular.js
-->

Also, if you use a package manager like Bower it’ll (in theory) install the dependencies for you (although of course you may need to still update your index.html file to update script src-es).

1 Like

I started using nightlies because there were features missing that I needed and show-stopper bugs. So I really don’t have much choice at this point. I’ll switch to stable at some point but as I’m developing I’m fine with it. I only run my script every few days and always make sure I check stuff into git first so that I can roll back if necessary.

I’ll look into the bundle, thanks.

Hey Adam,

You can use bower!

bower install driftyco/ionic-bower#master --save-dev

We push every bleeding-edge nightly build to ionic-bower repo. Unfortunately, bower install ionic still points to the main ionic repo (we are waiting on bower to fix something so we can move bower install ionic).

Then whenever you want to update, just bower update.

Sorry, that’s not going to happen. I find bower to be an incredibly misguided approach that solves almost nothing.

You see, I don’t want an entire copy of the ionic project living inside my application folder – even if I can (and would) exclude it from builds automatically. On top of that, it doesn’t put downloaded files anywhere useful. So after doing bower install/update, I then have to automate a copy step that copies the newly updated files into their useful location in my project. So why am I using bower again?

No thanks, I’ll stick with my custom bash script and wget.

Sorry to sort of unload on you, Andy – it’s certainly not your fault. I just don’t buy into the magic and wonder of bower one bit and I don’t see why everyone seems to be so hot on it.

@AdamTuttle have you thought about using grunt? I use bower to get all my js files and have a grunt task that moves the files i need to the proper location inside my www folder. This way my project file is clean and organized in a way i understand.

you can change the location of where bower_components folder is held in .bowerrc file.

For us we use bower_components and use a bundler to pick out the files that we need to serve to the client in one file.

It would be nice if you can include the ionic-bundle as part of the nightly builds.

@vialware we do !
http://code.ionicframework.com#nightly
http://code.ionicframework.com/nightly/js/ionic.bundle.js
http://code.ionicframework.com/nightly/js/ionic.bundle.min.js

@andy i’m using bower and it doesn’t appear to be part of the package.

@andy I’ve tried to install the nightly using bower and the command bower install driftyco/ionic-bower#master but I get this error no matches found: driftyco/ionic-bower#master

Sorry, solved… it was a zsh problem… I had to use bower install 'driftyco/ionic-bower#master'

Thanks

1 Like