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 8269047
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T06:05:32+00:00 2026-06-08T06:05:32+00:00

When I create a Grails app, it comes with some default files in the

  • 0

When I create a Grails app, it comes with some default files in the web-app directory:

$ find web-app
web-app
web-app/css
web-app/css/errors.css
web-app/css/main.css
web-app/css/mobile.css
web-app/images
web-app/images/apple-touch-icon-retina.png
web-app/images/apple-touch-icon.png
web-app/images/favicon.ico
web-app/images/grails_logo.jpg
web-app/images/grails_logo.png
web-app/images/leftnav_btm.png
web-app/images/leftnav_midstretch.png
web-app/images/leftnav_top.png
web-app/images/skin
web-app/images/skin/database_add.png
web-app/images/skin/database_delete.png
web-app/images/skin/database_edit.png
web-app/images/skin/database_save.png
web-app/images/skin/database_table.png
web-app/images/skin/exclamation.png
web-app/images/skin/house.png
web-app/images/skin/information.png
web-app/images/skin/shadow.jpg
web-app/images/skin/sorted_asc.gif
web-app/images/skin/sorted_desc.gif
web-app/images/spinner.gif
web-app/images/springsource.png
web-app/js
web-app/js/application.js

(META-INF and WEB-INF folders snipped from output)

These files create clutter in my app, and also use the common directory names css, images, and js, that I’m likely to want to use for my own resources.

In the past I’ve manually deleted these, but they return by themselves after running grails upgrade, overwriting my own files in the process.

I can’t see any reason to keep these files around. Is there something I’m missing? If not, how can I get rid of them and make sure they never come back?

  • 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-08T06:05:34+00:00Added an answer on June 8, 2026 at 6:05 am

    According to Burt Beckwith, the correct solution to this is to not use grails upgrade. Apparently, this is no longer the recommended way to upgrade a Grails application, because it really only does two important things, and that is to bump the version and then clean the app so everything is re-downloaded.

    Minor Upgrades

    From that posting, the recommended process for smaller version changes is:

    1. Edit application.properties and update the version.
    2. Then run grails clean to clear outdated files.
    3. Finally run grails compile and it’ll ask you if you want to upgrade the Hibernate and Tomcat plugins (if they’re listed in BuildConfig.groovy).

    You can also manually delete the old plugins in the work folder under the $HOME/.grails folder.

    Another tip Burt provides is:

    It’s even simpler if you add grails.project.work.dir = 'target' to BuildConfig.groovy. Then all your plugins will be there and you can just delete the whole target folder and all the plugins will be reinstalled and/or updated, and all the classes will be recompiled.

    Major Upgrades

    The process for major updates (such as upgrading a 1.x app to a 2.x app), is a little more involved:

    • create a new empty app in the new version of Grails
    • create a new empty app in the old version of Grails
    • diff your current app with the empty old-version app – this will tell you what you deleted, added, and changed. Copy new files over, delete stuff that should be deleted, and re-do the changes you made. Be sure to read the release notes and upgrade information for the intermediate Grails versions so you know how to make the new changes – e.g. HSQLDB -> H2 in DataSource.groovy, etc. Don’t just blindly make the same changes.

    Hopefully this will be documented eventually in the official docs, as it makes sense, since the upgrade process is too complicated to effectively be automated.


    New Applications

    This doesn’t, however, explain how to deal with new applications. Of course, you could simply just delete all Grails-specific files (which I recommend unless you use scaffolding).

    Another option is to move all the Grails-specific files into some subdirectory, then manually modify (and/or rename) the main layout, CSS files and resources links to point to these new locations.

    If you still want to use scaffolding, I recommend copying the main.gsp layout to scaffolding.gsp, and to create a new resources module just for scaffolding that contains all the default CSS and JS requirements. Then run grails install-templates, which will provide you with the basic view templates for scaffolding. You can then easily change the layout and add or update the correct resources module.

    Finally, once you’ve got your base application the way you want, zip it up and save it for later. That’s at least an easy way to only have to do all this once.

    Note
    After installing the templates, you probably won’t need the artifacts or war template folders, located under src/templates. Unless you know you use them, they should be deleted.


    As a final note, make sure you use a good, robust version control system, such as git or mercurial. This will make it easy to see what’s been modified if you accidentally run grails upgrade, and discard or roll back files you’d rather not change. With a decent IDE or GUI, you can usually fix this in a few clicks.

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

Sidebar

Related Questions

I can create a secure, multi-tenant web app with Grails by : setup spring
I create a new grails app and do grails install-plugin rest . App builds.
I started a grails application by grails create-app. For modularity, I feel like it
I want to create war using grails, but by default it creates war file
I have a Grails 2.0.0 project that was created using grails create-app . In
My grails app has to define some additional behaviour for many of the standard
I'm building a simple Grails app for a web development class. For the most
I'd like to have a mobile interface for my Grails app, and am wondering
I'm writing a web app using grails and spring-security 3.0.3 which requires me to
In a grails app, I have to create a bunch of grails domain classes

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.