Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9081641
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T20:21:47+00:00 2026-06-16T20:21:47+00:00

I would like to aggregate / assemble multiple js files into one without minifying

  • 0

I would like to aggregate / assemble multiple js files into one without minifying or obfuscating them using a maven plugin.
I am already using a yui plugin to obfuscate some js files into one:

       <plugin>
            <groupId>net.alchim31.maven</groupId>
            <artifactId>yuicompressor-maven-plugin</artifactId>
            <version>1.2</version>
            <executions>
                <execution>
                    <id>obfuscate</id>
                    <phase>process-resources</phase>
                    <goals>
                        <goal>compress</goal>
                    </goals>
                    <configuration>
                        <nosuffix>true</nosuffix>
                        <linebreakpos>-1</linebreakpos>
                        <aggregations>
                            <aggregation>
                                <removeIncluded>true</removeIncluded>
                                <insertNewLine>false</insertNewLine>
                                <output>${project.build.directory}/${project.build.finalName}/all.js</output>
                                <includes>
                                    <include>**/*.js</include>
                                </includes>
                                <excludes>
                                    <exclude>**/include/*.js</exclude>
                                </excludes>
                            </aggregation>
                        </aggregations>
                    </configuration>
                </execution>
            </executions>
        </plugin>

Now I want the same js files aggregated without minification or obfuscation in a file allForDev.js . The goal is to have one file for development and one for production. Its going to be useful to see the whole scripts when debugging in developer tools. If I don’t find a way to do this I’ll be forced to place a lot of script tags to load all those scirpts (which is not the end of the world 🙂 but I would like to do it in a cleaner way).

I can see that the assemble plugin has the following formats:

zip tar.gz tar.bz2 jar dir war and any other format that the
ArchiveManager has been configured for

Is there a way I can use the assemble maven plugin to do this? As much as I looked there were a bunch of examples to create zips jars and wars, but none to match what I want to do. Or did I miss something?

Is there another plugin I could use?

As a side note, I tried using a second execution of the yui plugin to create a second js file, but I had no luck in creating 2 files. I also tried providing 2 yui plugins, with no luck again. I think that’s not possible either.

Cheers,
Despot

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T20:21:49+00:00Added an answer on June 16, 2026 at 8:21 pm

    The answer would lie in wro4j library. For a more precise setup see:

    Javascript and CSS files combining in Maven build WITHOUT compression, minification etc

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to package multiple app in a single app. So donwloading one
I have 2 queries that I would like to combine into one. Basically I
I have 2 seperate select statements, using aggregate functions in each. I would like
I have objects in a tree structure, I would like to aggregate status information
I would like to concatenate a list of strings into new strings grouped over
I am using ASP.NET MVC2 and I would like to make up a url
here's my code: insert into archive from temp where temp.field6>archive.field6 i would like to
Using MYSQL I would like to refactor the following SELECT statement to return the
I have a database with many rows and I would like to consecutively aggregate
Does HQL support conditional expressions in aggregate functions? I would like to do something

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.