Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Difference of purpose of build and dist directories when doing a deploy

I am creating an ant script and I am wondering what should be the name of the directory where I package up the whole kaboodle and make it a .war file and put it in the webapps directory.

Should it be dist or build?

like image 688
Genadinik Avatar asked Apr 06 '11 17:04

Genadinik


People also ask

What is the difference between Dist and build folder?

Dist is for distribution and contains minified code. Build contains code that is not minified and not ready for production deployment.

What is a dist directory?

The dist folder, short for distribution folder, is dynamically generated when using the nuxt generate commands and includes the generated production ready HTML files and assets that are necessary to deploy and run your statically generated Nuxt application.

What is dist used for?

The shortform dist stands for distributable and refers to a directory where files will be stored that can be directly used by others without the need to compile or minify the source code that is being reused.

Is dist folder necessary?

The dist folder is for production website it's not necessary to have it. It will contain for example your image, css, script, vendor folder ready for production (minified and concatenated). You can check on google for this.


2 Answers

dist.

build is for the .class files only, while dist will include the WEB-INF, META-INF, libraries, etc

like image 191
Gandalf Avatar answered Oct 01 '22 19:10

Gandalf


Build and dist both contain files created by the build process. But dist contains the ones that you actually want to keep at the end of it.

like image 35
Tom Anderson Avatar answered Oct 01 '22 19:10

Tom Anderson