Skip to content

Commit

Permalink
cherry-picked "Remove dist folder, closes #820 (#840)"
Browse files Browse the repository at this point in the history
  • Loading branch information
zenflow authored and limonte committed Jan 29, 2018
1 parent e78c45d commit b11aab9
Show file tree
Hide file tree
Showing 14 changed files with 22 additions and 7,358 deletions.
6 changes: 0 additions & 6 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,3 @@ For bug reports, please include:
JSFiddle template: https://jsfiddle.net/ad3quksn/349/

JSFiddle template for IE11 and other old browsers: https://jsfiddle.net/ad3quksn/350/

---

For pull requests:

**Please make sure that `dist/*` files aren't committed.**
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
node_modules
package-lock.json
dist
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -166,8 +166,6 @@ If you would like to contribute enhancements or fixes, please do the following:
- in browser: http://localhost:8080/test/qunit/
- via CLI: `npm test`

6. Make sure that `dist/*` files aren't committed and create a pull request.


Related projects
-------------------------
Expand Down
23 changes: 15 additions & 8 deletions config/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ const banner = require('./banner.js')
const fs = require('fs')
const uglify = require('uglify-js')
const css = require('rollup-plugin-css-only')
const pify = require('pify')
const mkdirp = require('mkdirp')

const mkdirpAsync = pify(mkdirp)

const toUpper = (_, c) => {
return c ? c.toUpperCase() : ''
Expand All @@ -26,15 +30,18 @@ const write = (dest, code) => {

const packageRollup = (options) => {
const moduleId = classify(pack.name)
return rollup({
input: options.entry || 'src/sweetalert2.js',
plugins: [
css({ output: false }),
babel({
exclude: 'node_modules/**'
return mkdirpAsync('./dist')
.then(() => {
return rollup({
input: options.entry || 'src/sweetalert2.js',
plugins: [
css({ output: false }),
babel({
exclude: 'node_modules/**'
})
]
})
]
})
})
.then((bundle) => {
return bundle.generate({
format: options.format,
Expand Down
2,027 changes: 0 additions & 2,027 deletions dist/sweetalert2.all.js

This file was deleted.

1 change: 0 additions & 1 deletion dist/sweetalert2.all.min.js

This file was deleted.

Loading

0 comments on commit b11aab9

Please sign in to comment.