Skip to content
This repository was archived by the owner on Aug 14, 2021. It is now read-only.

Commit 94888fa

Browse files
committed
Move distribution files to /dist folder
1 parent dafee6b commit 94888fa

10 files changed

+90
-38
lines changed

.gitignore

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,10 @@
11
/.settings
2+
/dist
23
/node_modules
34
/test/triage/
45
.DS_Store
5-
npm-debug.log
6+
.pyftpsync-meta.json
67
.sizecache.json
8+
npm-debug.log
79
sauce_connect.log
810
sc_*.log
9-
10-
demo/.pyftpsync-meta.json
11-
12-
.pyftpsync-meta.json

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
# 2.0.0 / Unreleased branch: 'dist-folder'
2+
3+
* [BREAKING CHANGE] Distribution files moved from project root to /dist folder.
4+
15
# 1.18.2 / Unreleased
26

37
# 1.18.1 / 2017-08-28

Gruntfile.coffee

Lines changed: 27 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,14 @@
1-
#jshint node: true, camelcase: false
1+
#jshint node: true, camelcase: false
22
"use strict"
33
module.exports = (grunt) ->
44
grunt.initConfig
5-
pkg:
5+
pkg:
66
grunt.file.readJSON("package.json")
77

8+
clean:
9+
dist:
10+
src: [ "dist" ]
11+
812
connect:
913
demo:
1014
options:
@@ -24,6 +28,13 @@ module.exports = (grunt) ->
2428
base: ""
2529
keepalive: false
2630

31+
copy:
32+
dist: # copy production files to dist folder
33+
files: [{
34+
src: ["LICENSE.txt", "jquery.ui-contextmenu.js"]
35+
dest: "dist/"
36+
}]
37+
2738
exec:
2839
tabfix:
2940
# Cleanup whitespace according to http://contribute.jquery.org/style-guide/js/
@@ -104,7 +115,7 @@ module.exports = (grunt) ->
104115
# "http://localhost:9999/test/index.html",
105116
# "http://localhost:9999/test/index-jquery-ui-1-10.html"
106117
]
107-
118+
108119
# username: process.env.SAUCE_USERNAME,
109120
# key: process.env.SAUCE_ACCESS_KEY,
110121
build: process.env.TRAVIS_JOB_ID
@@ -164,8 +175,8 @@ module.exports = (grunt) ->
164175
build:
165176
options:
166177
sourceMap: true
167-
src: "jquery.ui-contextmenu.js"
168-
dest: "jquery.ui-contextmenu.min.js"
178+
src: "dist/jquery.ui-contextmenu.js"
179+
dest: "dist/jquery.ui-contextmenu.min.js"
169180

170181
watch:
171182
dev:
@@ -189,7 +200,7 @@ module.exports = (grunt) ->
189200
bump: {} # 'bump' uses the increment mode `yabs:release:MODE` by default
190201
run_build: { tasks: ['build'] }
191202
replace_build:
192-
files: ['jquery.ui-contextmenu.min.js']
203+
files: ['dist/jquery.ui-contextmenu.min.js', 'dist/jquery.ui-contextmenu.js']
193204
patterns: [
194205
{ match: /@VERSION/g, replacement: '{%= version %}'}
195206
]
@@ -208,8 +219,8 @@ module.exports = (grunt) ->
208219

209220
# Load "grunt*" dependencies
210221
for key of grunt.file.readJSON("package.json").devDependencies
211-
grunt.loadNpmTasks key if key isnt "grunt" and key.indexOf("grunt") is 0
212-
222+
grunt.loadNpmTasks key if key isnt "grunt" and key.indexOf("grunt") is 0
223+
213224
grunt.registerTask "server", ["connect:demo"]
214225
grunt.registerTask "dev", ["connect:dev", "watch:dev"]
215226
grunt.registerTask "test", ["jshint", "jscs", "qunit"]
@@ -222,8 +233,14 @@ module.exports = (grunt) ->
222233
grunt.registerTask "travis", ["test", "sauce"]
223234
grunt.registerTask "default", ["test"]
224235
grunt.registerTask "ci", ["test"] # Called by 'npm test'
225-
236+
226237
# "sauce",
227-
grunt.registerTask "build", ["exec:tabfix", "test", "uglify"]
238+
grunt.registerTask "build", [
239+
# "exec:tabfix"
240+
"test"
241+
"clean:dist"
242+
"copy:dist"
243+
"uglify"
244+
]
228245
grunt.registerTask "upload", ["build", "exec:upload"]
229246
grunt.registerTask "server", ["connect:demo"]

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,9 @@ First, include dependencies:
5353

5454
```html
5555
<head>
56-
<link href="//code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css" rel="stylesheet" />
57-
<script src="//code.jquery.com/jquery-1.11.3.min.js"></script>
58-
<script src="//code.jquery.com/ui/1.11.4/jquery-ui.min.js"></script>
56+
<link href="//code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css" rel="stylesheet" />
57+
<script src="//code.jquery.com/jquery-3.2.1.min.js"></script>
58+
<script src="//code.jquery.com/ui/1.12.1/jquery-ui.min.js"></script>
5959
<script src="assets/jquery.ui-contextmenu.min.js"></script>
6060
```
6161

bower.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"description": "Turn a jQuery UI Menu widget into a contextmenu.",
44
"version": "1.18.2-0",
55
"main": [
6-
"jquery.ui-contextmenu.js"
6+
"dist/jquery.ui-contextmenu.js"
77
],
88
"moduleType": "globals",
99
"license": "MIT",
@@ -14,7 +14,6 @@
1414
"/lib",
1515
"/test",
1616
"bower.json",
17-
"ui-contextmenu.jquery.json",
1817
"Gruntfile.coffee"
1918
],
2019
"keywords": [
@@ -44,4 +43,4 @@
4443
"jquery-ui": ">=1.9"
4544
},
4645
"devDependencies": {}
47-
}
46+
}

jquery.ui-contextmenu.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ $.widget("moogle.contextmenu", {
4343
menu: null, // selector or jQuery pointing to <UL>, or a definition hash
4444
position: null, // popup positon
4545
preventContextMenuForPopup: false, // prevent opening the browser's system
46-
// context menu on menu entries
46+
// context menu on menu entries
4747
preventSelect: false, // disable text selection of target
4848
show: { effect: "slideDown", duration: "fast" },
4949
taphold: false, // open menu on taphold events (requires external plugins)

jquery.ui-contextmenu.min.js

Lines changed: 0 additions & 4 deletions
This file was deleted.

0 commit comments

Comments
 (0)