From 3923fd264ce54e077e4448c68b6a4144a834ca35 Mon Sep 17 00:00:00 2001 From: Kazuhiro MUSASHI Date: Sat, 18 Apr 2020 23:00:23 +0800 Subject: [PATCH 1/3] Add `--minify` option to `Rakefile` task. --- tasks/production.rake | 2 +- tasks/staging.rake | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tasks/production.rake b/tasks/production.rake index 17e28dd..acf47b4 100644 --- a/tasks/production.rake +++ b/tasks/production.rake @@ -4,7 +4,7 @@ require 'find' desc 'Deploy the hugo contents to the server' task :prod => [:prep] do - sh 'hugo -v' + sh 'hugo -v --minify' sh 'find public -type f -name "*.gz" -delete' diff --git a/tasks/staging.rake b/tasks/staging.rake index 08d94c5..647953f 100644 --- a/tasks/staging.rake +++ b/tasks/staging.rake @@ -4,7 +4,7 @@ require 'find' desc 'Deploy the hugo contents to the server' task :stag => [:prep] do - sh 'hugo -e staging -v' + sh 'hugo -e staging -v --minify' sh 'find public -type f -name "*.gz" -delete' From bdec22a19a14e4dddc9a12fbf5833c62d4c287d6 Mon Sep 17 00:00:00 2001 From: Kazuhiro MUSASHI Date: Sat, 18 Apr 2020 23:04:04 +0800 Subject: [PATCH 2/3] Add `--minify` option to `.drone.yml`. --- .drone.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.drone.yml b/.drone.yml index c6ceed1..33a6fc8 100644 --- a/.drone.yml +++ b/.drone.yml @@ -12,7 +12,7 @@ steps: - name: hugo image: cibuilds/hugo:0.69.0 commands: - - sudo hugo -e production -v -s . + - sudo hugo -e production -v -s --minify . - name: Compress-the-Assets image: alpine:3.9 @@ -66,7 +66,7 @@ steps: - name: hugo image: cibuilds/hugo:0.69.0 commands: - - sudo hugo -e staging -v -s . + - sudo hugo -e staging -v -s --minify . - name: Compress-the-Assets image: alpine:3.9 From 20d9abf6245c9bb6cb072eb5afffe735c5fc2d79 Mon Sep 17 00:00:00 2001 From: Kazuhiro MUSASHI Date: Sat, 18 Apr 2020 23:11:38 +0800 Subject: [PATCH 3/3] Modify `--minify` option order. --- .drone.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.drone.yml b/.drone.yml index 33a6fc8..140630f 100644 --- a/.drone.yml +++ b/.drone.yml @@ -12,7 +12,7 @@ steps: - name: hugo image: cibuilds/hugo:0.69.0 commands: - - sudo hugo -e production -v -s --minify . + - sudo hugo -e production --minify -v -s . - name: Compress-the-Assets image: alpine:3.9 @@ -66,7 +66,7 @@ steps: - name: hugo image: cibuilds/hugo:0.69.0 commands: - - sudo hugo -e staging -v -s --minify . + - sudo hugo -e staging --minify -v -s . - name: Compress-the-Assets image: alpine:3.9