Return-Path: X-Original-To: apmail-brooklyn-commits-archive@minotaur.apache.org Delivered-To: apmail-brooklyn-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id ADDDB11247 for ; Fri, 23 May 2014 14:52:12 +0000 (UTC) Received: (qmail 83447 invoked by uid 500); 23 May 2014 14:52:12 -0000 Delivered-To: apmail-brooklyn-commits-archive@brooklyn.apache.org Received: (qmail 83426 invoked by uid 500); 23 May 2014 14:52:12 -0000 Mailing-List: contact commits-help@brooklyn.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@brooklyn.incubator.apache.org Delivered-To: mailing list commits@brooklyn.incubator.apache.org Received: (qmail 83389 invoked by uid 99); 23 May 2014 14:52:12 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 23 May 2014 14:52:12 +0000 X-ASF-Spam-Status: No, hits=-2000.7 required=5.0 tests=ALL_TRUSTED,RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.3] (HELO mail.apache.org) (140.211.11.3) by apache.org (qpsmtpd/0.29) with SMTP; Fri, 23 May 2014 14:51:57 +0000 Received: (qmail 81723 invoked by uid 99); 23 May 2014 14:51:33 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 23 May 2014 14:51:33 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id 0DF0F9A46E6; Fri, 23 May 2014 14:51:33 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: richard@apache.org To: commits@brooklyn.incubator.apache.org Date: Fri, 23 May 2014 14:51:53 -0000 Message-Id: <2a3112e9cbd542838e175204cbbefc6d@git.apache.org> In-Reply-To: References: X-Mailer: ASF-Git Admin Mailer Subject: [22/50] [abbrv] git commit: Rework gzipping of jsgui resources X-Virus-Checked: Checked by ClamAV on apache.org Rework gzipping of jsgui resources Uses an ant gzip task rather than the custom bash script that breaks the build on Windows. Project: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/commit/2f407ca6 Tree: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/tree/2f407ca6 Diff: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/diff/2f407ca6 Branch: refs/pull/1410/merge Commit: 2f407ca6f497335088a13b88f6d557a4f2af87bb Parents: e347267 Author: Sam Corbett Authored: Thu May 22 16:13:20 2014 +0100 Committer: Sam Corbett Committed: Thu May 22 16:13:20 2014 +0100 ---------------------------------------------------------------------- usage/jsgui/build/gzip-with-redirect.sh | 23 -------------------- usage/jsgui/pom.xml | 32 ++++++++++++---------------- 2 files changed, 14 insertions(+), 41 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/2f407ca6/usage/jsgui/build/gzip-with-redirect.sh ---------------------------------------------------------------------- diff --git a/usage/jsgui/build/gzip-with-redirect.sh b/usage/jsgui/build/gzip-with-redirect.sh deleted file mode 100755 index ef0c68e..0000000 --- a/usage/jsgui/build/gzip-with-redirect.sh +++ /dev/null @@ -1,23 +0,0 @@ -#!/usr/bin/env sh - -# This script is a fairly grim workaround for the following scenario: -# * We'd like certain files to be compressed with gzip at build time so -# Jersey can serve the compressed content when the Accept-Encoding:gzip -# header is given. -# * We want to keep the input files given to gzip so that we serve files -# correctly if a request's Accept-Encoding header is none. -# * By default gzip replaces input files with its compressed output. This -# can be surpressed with the -k flag, but -k is a relatively new addition -# to gzip and its presence can't be relied on. So we're stuck with -c -# and redirecting stdout. -# * The exec-maven-plugin is a handy tool for executing arbitrary commands -# at build. Sadly, it does not produce valid .gz files when the outputFile -# parameter is given. -# * Hence this script. - -# When exec-maven-plugin 1.3 is released we should revisit this file. - -for f in $@; do - gzip --best -c $f > $f.gz -done - http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/2f407ca6/usage/jsgui/pom.xml ---------------------------------------------------------------------- diff --git a/usage/jsgui/pom.xml b/usage/jsgui/pom.xml index 9afea51..2fcd1b3 100644 --- a/usage/jsgui/pom.xml +++ b/usage/jsgui/pom.xml @@ -30,7 +30,7 @@ 2.0.2 - 1.2.1 + 1.7 ${project.build.directory}/${project.build.finalName} @@ -273,31 +273,27 @@ - org.codehaus.mojo - exec-maven-plugin - ${exec-maven-plugin.version} - - ${project.basedir}/build/gzip-with-redirect.sh - + maven-antrun-plugin - - gzip-resources + Compress resources prepare-package - exec + run - - ${project.build.webapp}/assets/css/styles.min.css - ${project.build.webapp}/assets/css/brooklyn.css - ${project.build.webapp}/assets/js/gui.min.js - ${project.build.webapp}/assets/js/libs/require.js - + + + + + + -