From 33c8659939efce078df3eb5e83be7f8a806eb798 Mon Sep 17 00:00:00 2001 From: Mitja Kramberger Date: Thu, 4 Oct 2018 16:02:40 +0100 Subject: [PATCH 1/3] chore: prework for npm publish --- .npmignore | 2 ++ Rakefile | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/.npmignore b/.npmignore index f33585aa..9068122e 100644 --- a/.npmignore +++ b/.npmignore @@ -1,2 +1,4 @@ * !assets/stylesheets/**/* +!assets/images/**/* +!assets/icons/**/* diff --git a/Rakefile b/Rakefile index f6e5e426..66e99bcf 100644 --- a/Rakefile +++ b/Rakefile @@ -54,6 +54,11 @@ namespace :shipyard do end end + desc 'Publish project to npm as scoped package @codeship/shipyard' + task :console do + sh 'npm publish --access public' + end + desc 'Compiles Shipyard and custom icons into an external svg definitions file.' task :icons, [:icon_directory, :output_directory] do |t, args| args.with_defaults(:icon_directory => '/app/assets/icons/', :output_directory => '/public/assets/') From 5ecce49098937697ad3d327a913d41a10d70aea0 Mon Sep 17 00:00:00 2001 From: Mitja Kramberger Date: Thu, 4 Oct 2018 16:37:46 +0100 Subject: [PATCH 2/3] fix --- Rakefile | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Rakefile b/Rakefile index 66e99bcf..94940092 100644 --- a/Rakefile +++ b/Rakefile @@ -54,15 +54,15 @@ namespace :shipyard do end end - desc 'Publish project to npm as scoped package @codeship/shipyard' - task :console do - sh 'npm publish --access public' - end - desc 'Compiles Shipyard and custom icons into an external svg definitions file.' task :icons, [:icon_directory, :output_directory] do |t, args| args.with_defaults(:icon_directory => '/app/assets/icons/', :output_directory => '/public/assets/') icons = Shipyard::Icons.new args.icon_directory, args.output_directory icons.write end + + desc 'Publish project to npm as a scoped package @codeship/shipyard' + task :console do + sh 'npm publish --access public' + end end From 61345a9d9bf22dd7604dae0dbf902facadbced42 Mon Sep 17 00:00:00 2001 From: Mitja Kramberger Date: Thu, 4 Oct 2018 18:21:47 +0100 Subject: [PATCH 3/3] another fix --- Rakefile | 5 ----- ci/npm | 5 +++++ codeship-steps.yml | 4 ++++ 3 files changed, 9 insertions(+), 5 deletions(-) create mode 100644 ci/npm diff --git a/Rakefile b/Rakefile index 94940092..f6e5e426 100644 --- a/Rakefile +++ b/Rakefile @@ -60,9 +60,4 @@ namespace :shipyard do icons = Shipyard::Icons.new args.icon_directory, args.output_directory icons.write end - - desc 'Publish project to npm as a scoped package @codeship/shipyard' - task :console do - sh 'npm publish --access public' - end end diff --git a/ci/npm b/ci/npm new file mode 100644 index 00000000..4d6af039 --- /dev/null +++ b/ci/npm @@ -0,0 +1,5 @@ +#!/bin/bash +set -e # halt script on error + +echo -e "\n\n************** NPM publish for @codeship/shipyard **************" +npm publish --access public \ No newline at end of file diff --git a/codeship-steps.yml b/codeship-steps.yml index 75d230d9..adf3ca9b 100644 --- a/codeship-steps.yml +++ b/codeship-steps.yml @@ -42,3 +42,7 @@ service: shipyard name: GitHub Pages command: ./ci/github + - + service: shipyard + name: NPM publish + command: ./ci/npm