From 522b11ce164907a31f66621adaf0f20fc0ca765d Mon Sep 17 00:00:00 2001 From: Kazuhiro MUSASHI Date: Sun, 16 Jun 2019 17:22:59 +0700 Subject: [PATCH 2/2] =?UTF-8?q?Mac=20OS=E5=90=91=E3=81=91=E3=81=AB?= =?UTF-8?q?=E3=82=AA=E3=83=97=E3=82=B7=E3=83=A7=E3=83=B3=E3=82=92=E5=A4=89?= =?UTF-8?q?=E6=9B=B4:?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ``` --- a/tasks/build.rake +++ b/tasks/build.rake @@ -24,12 +24,14 @@ task :build do if os == :linux sh 'grep -l -r ecx.images-amazon.com | sort | uniq | xargs --no-run-if-empty sed -ie "s/http:\/\/ecx.images-amazon.com/https:\/\/images-na.ssl-images-amazon.com/g"' sh 'grep -l -r "http://www.amazon.co.jp/exec" | sort | uniq | xargs --no-run-if-empty sed -i -e "s/http:\/\/www.amazon.co.jp\/exec/https:\/\/www.amazon.co.jp\/exec/g"' + sh 'find . -type f -name "*.mde" | xargs --no-run-if-empty rm || true' + sh 'find . -type f -name "*.md-e" | xargs --no-run-if-empty rm || true' else - sh 'grep -l -r ecx.images-amazon.com | sort | uniq | xargs d -ie "s/http:\/\/ecx.images-amazon.com/https:\/\/images-na.ssl-images-amazon.com/g"' - sh 'grep -l -r "http://www.amazon.co.jp/exec" | sort | uniq | xargs sed -i -e "s/http:\/\/www.amazon.co.jp\/exec/https:\/\/www.amazon.co.jp\/exec/g"' + sh 'grep -l -r ecx.images-amazon.com . | sort | uniq | xargs d -ie "s/http:\/\/ecx.images-amazon.com/https:\/\/images-na.ssl-images-amazon.com/g"' + sh 'grep -l -r "http://www.amazon.co.jp/exec" . | sort | uniq | xargs sed -i -e "s/http:\/\/www.amazon.co.jp\/exec/https:\/\/www.amazon.co.jp\/exec/g"' + sh 'find . -type f -name "*.mde" | xargs rm || true' + sh 'find . -type f -name "*.md-e" | xargs rm || true' end - sh 'find . -type f -name "*.mde" | xargs --no-run-if-empty rm || true' - sh 'find . -type f -name "*.md-e" | xargs --no-run-if-empty rm || true' end cd 'public' do ``` --- tasks/build.rake | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) mode change 100644 => 100755 tasks/build.rake diff --git a/tasks/build.rake b/tasks/build.rake old mode 100644 new mode 100755 index 5040252..864b1f9 --- a/tasks/build.rake +++ b/tasks/build.rake @@ -24,12 +24,14 @@ task :build do if os == :linux sh 'grep -l -r ecx.images-amazon.com | sort | uniq | xargs --no-run-if-empty sed -ie "s/http:\/\/ecx.images-amazon.com/https:\/\/images-na.ssl-images-amazon.com/g"' sh 'grep -l -r "http://www.amazon.co.jp/exec" | sort | uniq | xargs --no-run-if-empty sed -i -e "s/http:\/\/www.amazon.co.jp\/exec/https:\/\/www.amazon.co.jp\/exec/g"' + sh 'find . -type f -name "*.mde" | xargs --no-run-if-empty rm || true' + sh 'find . -type f -name "*.md-e" | xargs --no-run-if-empty rm || true' else - sh 'grep -l -r ecx.images-amazon.com | sort | uniq | xargs d -ie "s/http:\/\/ecx.images-amazon.com/https:\/\/images-na.ssl-images-amazon.com/g"' - sh 'grep -l -r "http://www.amazon.co.jp/exec" | sort | uniq | xargs sed -i -e "s/http:\/\/www.amazon.co.jp\/exec/https:\/\/www.amazon.co.jp\/exec/g"' + sh 'grep -l -r ecx.images-amazon.com . | sort | uniq | xargs d -ie "s/http:\/\/ecx.images-amazon.com/https:\/\/images-na.ssl-images-amazon.com/g"' + sh 'grep -l -r "http://www.amazon.co.jp/exec" . | sort | uniq | xargs sed -i -e "s/http:\/\/www.amazon.co.jp\/exec/https:\/\/www.amazon.co.jp\/exec/g"' + sh 'find . -type f -name "*.mde" | xargs rm || true' + sh 'find . -type f -name "*.md-e" | xargs rm || true' end - sh 'find . -type f -name "*.mde" | xargs --no-run-if-empty rm || true' - sh 'find . -type f -name "*.md-e" | xargs --no-run-if-empty rm || true' end cd 'public' do