Release v2.0.2

This commit is contained in:
benweet 2013-09-03 14:40:23 +01:00
parent 7185c16072
commit af61a49e29
10 changed files with 25 additions and 67 deletions

View File

@ -6,6 +6,7 @@ module.exports = function(grunt) {
grunt.loadNpmTasks('grunt-contrib-copy'); grunt.loadNpmTasks('grunt-contrib-copy');
grunt.loadNpmTasks('grunt-bower-requirejs'); grunt.loadNpmTasks('grunt-bower-requirejs');
grunt.loadNpmTasks('grunt-bump'); grunt.loadNpmTasks('grunt-bump');
grunt.loadNpmTasks('grunt-shell');
/*************************************************************************** /***************************************************************************
* Configuration * Configuration
@ -157,7 +158,22 @@ module.exports = function(grunt) {
], ],
updateConfigs: [ updateConfigs: [
'pkg' 'pkg'
] ],
commitFiles: ['-a'],
pushTo: 'origin'
}
},
shell: {
deploy: {
options: {
stdout: true,
stderr: true,
failOnError: true
},
command: [
'git branch -f gh-pages master',
'git push --all origin'
].join('&&')
} }
} }
}); });
@ -242,8 +258,10 @@ module.exports = function(grunt) {
* Deploy task * Deploy task
*/ */
grunt.registerTask('deploy', function() { grunt.registerTask('deploy', function() {
grunt.task.run('bump-only:patch'); grunt.task.run('bump-only');
grunt.task.run('string-replace:config'); grunt.task.run('string-replace:config');
grunt.task.run('default'); grunt.task.run('default');
grunt.task.run('bump-commit');
grunt.task.run('shell');
}); });
}; };

View File

@ -1,6 +1,6 @@
{ {
"name": "stackedit", "name": "stackedit",
"version": "2.0.0", "version": "2.0.2",
"description": "StackEdit is a free, open-source Markdown editor based on PageDown, the Markdown library used by Stack Overflow and the other Stack Exchange sites.", "description": "StackEdit is a free, open-source Markdown editor based on PageDown, the Markdown library used by Stack Overflow and the other Stack Exchange sites.",
"dependencies": { "dependencies": {
"bootstrap": "3.0.0", "bootstrap": "3.0.0",

View File

@ -1,5 +1,5 @@
CACHE MANIFEST CACHE MANIFEST
#Date Tue Sep 03 2013 13:01:08 #Date Tue Sep 03 2013 14:40:23
CACHE: CACHE:
index.html index.html

View File

@ -1,6 +1,6 @@
{ {
"name": "stackedit", "name": "stackedit",
"version": "2.0.1", "version": "2.0.2",
"description": "StackEdit is a free, open-source Markdown editor based on PageDown, the Markdown library used by Stack Overflow and the other Stack Exchange sites.", "description": "StackEdit is a free, open-source Markdown editor based on PageDown, the Markdown library used by Stack Overflow and the other Stack Exchange sites.",
"main": "res/main.js", "main": "res/main.js",
"directories": { "directories": {

View File

@ -4353,7 +4353,7 @@ printStackTrace.implementation = function() {}, printStackTrace.implementation.p
}, utils; }, utils;
}); });
var VERSION = "2.0.0", MAIN_URL = "http://benweet.github.io/stackedit/", GOOGLE_ANALYTICS_ACCOUNT_ID = "UA-39556145-1", GOOGLE_API_KEY = "AIzaSyAeCU8CGcSkn0z9js6iocHuPBX4f_mMWkw", GOOGLE_SCOPES = [ "https://www.googleapis.com/auth/drive.install", "https://www.googleapis.com/auth/drive", "https://www.googleapis.com/auth/blogger", "https://picasaweb.google.com/data/" ], GOOGLE_DRIVE_APP_ID = "241271498917", DROPBOX_APP_KEY = "lq6mwopab8wskas", DROPBOX_APP_SECRET = "851fgnucpezy84t", BITLY_ACCESS_TOKEN = "317e033bfd48cf31155a68a536b1860013b09c4c", DEFAULT_FILE_TITLE = "Title", DEFAULT_FOLDER_NAME = "New folder", GDRIVE_DEFAULT_FILE_TITLE = "New Markdown document", CHECK_ONLINE_PERIOD = 12e4, AJAX_TIMEOUT = 3e4, ASYNC_TASK_DEFAULT_TIMEOUT = 6e4, ASYNC_TASK_LONG_TIMEOUT = 18e4, SYNC_PERIOD = 18e4, USER_IDLE_THRESHOLD = 3e5, IMPORT_FILE_MAX_CONTENT_SIZE = 1e5, IMPORT_IMG_MAX_CONTENT_SIZE = 1e7, TEMPORARY_FILE_INDEX = "file.tempIndex", WELCOME_DOCUMENT_TITLE = "Welcome document", DOWNLOAD_PROXY_URL = "http://stackedit-download-proxy.herokuapp.com/", PICASA_PROXY_URL = "http://stackedit-picasa-proxy.herokuapp.com/", WORDPRESS_CLIENT_ID = "3185", WORDPRESS_PROXY_URL = "http://stackedit-wordpress-proxy.herokuapp.com/", SSH_PROXY_URL = "http://stackedit-ssh-proxy.herokuapp.com/", delayedFunction = void 0, BASE_URL = "http://localhost/stackedit/", GOOGLE_CLIENT_ID = "241271498917-lev37kef013q85avc91am1gccg5g8lrb.apps.googleusercontent.com", GITHUB_CLIENT_ID = "e47fef6055344579799d", GATEKEEPER_URL = "http://stackedit-gatekeeper-localhost.herokuapp.com/", TUMBLR_PROXY_URL = "http://stackedit-tumblr-proxy-local.herokuapp.com/"; var VERSION = "2.0.2", MAIN_URL = "http://benweet.github.io/stackedit/", GOOGLE_ANALYTICS_ACCOUNT_ID = "UA-39556145-1", GOOGLE_API_KEY = "AIzaSyAeCU8CGcSkn0z9js6iocHuPBX4f_mMWkw", GOOGLE_SCOPES = [ "https://www.googleapis.com/auth/drive.install", "https://www.googleapis.com/auth/drive", "https://www.googleapis.com/auth/blogger", "https://picasaweb.google.com/data/" ], GOOGLE_DRIVE_APP_ID = "241271498917", DROPBOX_APP_KEY = "lq6mwopab8wskas", DROPBOX_APP_SECRET = "851fgnucpezy84t", BITLY_ACCESS_TOKEN = "317e033bfd48cf31155a68a536b1860013b09c4c", DEFAULT_FILE_TITLE = "Title", DEFAULT_FOLDER_NAME = "New folder", GDRIVE_DEFAULT_FILE_TITLE = "New Markdown document", CHECK_ONLINE_PERIOD = 12e4, AJAX_TIMEOUT = 3e4, ASYNC_TASK_DEFAULT_TIMEOUT = 6e4, ASYNC_TASK_LONG_TIMEOUT = 18e4, SYNC_PERIOD = 18e4, USER_IDLE_THRESHOLD = 3e5, IMPORT_FILE_MAX_CONTENT_SIZE = 1e5, IMPORT_IMG_MAX_CONTENT_SIZE = 1e7, TEMPORARY_FILE_INDEX = "file.tempIndex", WELCOME_DOCUMENT_TITLE = "Welcome document", DOWNLOAD_PROXY_URL = "http://stackedit-download-proxy.herokuapp.com/", PICASA_PROXY_URL = "http://stackedit-picasa-proxy.herokuapp.com/", WORDPRESS_CLIENT_ID = "3185", WORDPRESS_PROXY_URL = "http://stackedit-wordpress-proxy.herokuapp.com/", SSH_PROXY_URL = "http://stackedit-ssh-proxy.herokuapp.com/", delayedFunction = void 0, BASE_URL = "http://localhost/stackedit/", GOOGLE_CLIENT_ID = "241271498917-lev37kef013q85avc91am1gccg5g8lrb.apps.googleusercontent.com", GITHUB_CLIENT_ID = "e47fef6055344579799d", GATEKEEPER_URL = "http://stackedit-gatekeeper-localhost.herokuapp.com/", TUMBLR_PROXY_URL = "http://stackedit-tumblr-proxy-local.herokuapp.com/";
0 === location.hostname.indexOf("benweet.github.io") && (BASE_URL = MAIN_URL, GOOGLE_CLIENT_ID = "241271498917-jpto9lls9fqnem1e4h6ppds9uob8rpvu.apps.googleusercontent.com", 0 === location.hostname.indexOf("benweet.github.io") && (BASE_URL = MAIN_URL, GOOGLE_CLIENT_ID = "241271498917-jpto9lls9fqnem1e4h6ppds9uob8rpvu.apps.googleusercontent.com",
GITHUB_CLIENT_ID = "fa0d09514da8377ee32e", GATEKEEPER_URL = "http://stackedit-gatekeeper.herokuapp.com/", GITHUB_CLIENT_ID = "fa0d09514da8377ee32e", GATEKEEPER_URL = "http://stackedit-gatekeeper.herokuapp.com/",

View File

@ -1,4 +1,4 @@
var VERSION = "2.0.0"; var VERSION = "2.0.2";
var MAIN_URL = "http://benweet.github.io/stackedit/"; var MAIN_URL = "http://benweet.github.io/stackedit/";
var GOOGLE_ANALYTICS_ACCOUNT_ID = "UA-39556145-1"; var GOOGLE_ANALYTICS_ACCOUNT_ID = "UA-39556145-1";

View File

@ -1,8 +0,0 @@
#!/bin/sh
set -e
echo '### Optimizing resources ###'
tools/run_optimize
echo '### Commit and push ###'
git commit -a -m "Prepare deployment"
git branch -f gh-pages master
git push --all

View File

@ -1,4 +0,0 @@
#!/bin/sh
version_minor=`sed 's/.*-\([0-9]*\)/\1/' version`
((version_minor++))
sed -i '' "s/\(.*-\)[0-9]*/\1$version_minor/" version

View File

@ -1,19 +0,0 @@
// RequireJS optimizer configuration file
({
baseUrl: "../res",
name: "main",
out: "../res-min/main.js",
mainConfigFile: '../res/main.js',
optimize: "uglify2",
uglify2: {
output: {
beautify: true,
indent_level: 1,
},
},
excludeShallow: [
'css/css-builder',
'less/lessc-server',
'less/lessc'
],
})

View File

@ -1,29 +0,0 @@
#!/bin/sh
echo
echo '### Installing dependencies ###'
npm install requirejs
npm install less
export PATH=${PATH}:`pwd`/node_modules/requirejs/bin/:`pwd`/node_modules/less/bin/
echo
echo '### Optimizing JavaScript ###'
rm -rf res-min
r.js -o tools/optimize-js.json
echo
echo '### Optimizing CSS ###'
mkdir -p res-min/themes
cd res/themes
for theme in *; do lessc $theme | sed 's/@import/@import (less)/g' | lessc -x - > `echo ../../res-min/themes/${theme} | sed 's/.less$/.css/'`; done
cd ../..
cp -R res/libs/fontello/font res-min/
cp -R res/img res-min/
echo
echo '### Updating cache.manifest ###'
sed -n '1,/#dynamic/p' cache.manifest > cache.manifest.new
printf "\n# `date`\n" >> cache.manifest.new
find res-min -type f >> cache.manifest.new
printf "\nNETWORK:\n*" >> cache.manifest.new
mv cache.manifest.new cache.manifest