Compare commits
83 Commits
Author | SHA1 | Date | |
---|---|---|---|
f8c61cfe0c | |||
c6dd4d18f3 | |||
dbf8072343 | |||
d7c6231e78 | |||
816639f51b | |||
1015173f28 | |||
f9823258ac | |||
3ae5474ec0 | |||
44aded6d40 | |||
cf8bdc97d8 | |||
cbb249ccdc | |||
42c9eacf4f | |||
37789c7a66 | |||
e7d8bcdcc4 | |||
abd1d24f9b | |||
b54f83acb6 | |||
2e93696ce7 | |||
bf2c9f765e | |||
6eea416121 | |||
44645aa38c | |||
457d1e3d62 | |||
d711698c55 | |||
7b625bd10c | |||
897bfd5ac9 | |||
7a7e619133 | |||
d35308f1df | |||
bbacd6d8ed | |||
ba6f8663e3 | |||
1aa27aeb42 | |||
d6569f6ed3 | |||
a0485331ae | |||
1692822914 | |||
e5f0197170 | |||
992e55dec6 | |||
18764e7d12 | |||
b1e18d0c56 | |||
d7102ae0bd | |||
ef6d253896 | |||
c9be4f9452 | |||
978d6ef832 | |||
2be28f4d3d | |||
5e94b69aa0 | |||
f589e71686 | |||
0caacd6223 | |||
d6608ab263 | |||
0501123763 | |||
24506def11 | |||
e9a5e27266 | |||
db9e832984 | |||
d64a228a8b | |||
5c44830746 | |||
13ea6514f8 | |||
3f130c08cb | |||
9bdd17d456 | |||
375c496ff9 | |||
4537f750ca | |||
590626fc85 | |||
9840b54f54 | |||
2a2cf7190f | |||
bd7f84c8f0 | |||
f6c72be223 | |||
b8e96a33b1 | |||
621173555c | |||
16594369d8 | |||
d98ddef0b9 | |||
21cc6c1fdb | |||
7c8e183cb7 | |||
c6e90cbf9f | |||
062d30b056 | |||
d82981c995 | |||
843a61b25a | |||
69a2a76192 | |||
6f6d2b84b3 | |||
16dbfea134 | |||
635eb88cdd | |||
8cdd554db2 | |||
d489504a88 | |||
05edee6f3c | |||
9e2ad39f39 | |||
1b023a58c7 | |||
fcb5563e29 | |||
d4c869a442 | |||
e6e2f20d80 |
@ -1,25 +0,0 @@
|
||||
engines:
|
||||
csslint:
|
||||
enabled: true
|
||||
duplication:
|
||||
enabled: true
|
||||
config:
|
||||
languages:
|
||||
- javascript
|
||||
eslint:
|
||||
enabled: true
|
||||
checks:
|
||||
wrap-iife:
|
||||
enabled: false
|
||||
fixme:
|
||||
enabled: true
|
||||
ratings:
|
||||
paths:
|
||||
- "**.css"
|
||||
- "**.js"
|
||||
exclude_paths:
|
||||
- .github/
|
||||
- bin/
|
||||
- misc/
|
||||
- src/js/lib/
|
||||
- test/
|
@ -1,2 +0,0 @@
|
||||
# Exclude libs.
|
||||
**/lib/**/*.js
|
19
.github/ISSUE_TEMPLATE
vendored
@ -1,19 +0,0 @@
|
||||
Bug description
|
||||
|
||||
(this template is intended for bug reports, erase it when requesting features/enhancements)
|
||||
|
||||
### Steps to reproduce the bug
|
||||
1. go to piskelapp.com
|
||||
2. select a tool
|
||||
3. ...
|
||||
|
||||
### Environment details
|
||||
* operating system:
|
||||
* browser (or offline application version):
|
||||
|
||||
### Sprite details
|
||||
* number of frames:
|
||||
* sprite resolution:
|
||||
* session duration:
|
||||
|
||||
Feel free to include a screenshot of the bug, a .piskel file of the sprite or anything else that can help us investigate.
|
32
.gitignore
vendored
@ -1,40 +1,12 @@
|
||||
# mac artifacts
|
||||
# mac artefacts
|
||||
*.DS_Store
|
||||
|
||||
# nodejs local installs
|
||||
node_modules
|
||||
npm-debug.log
|
||||
|
||||
# node webkit cache
|
||||
cache
|
||||
|
||||
# sublime text stuff (the -project should actually be shared, but then we'd have to share the same disk location)
|
||||
*.sublime-project
|
||||
*.sublime-workspace
|
||||
|
||||
# netbeans project folder
|
||||
nbproject
|
||||
|
||||
# vscode workspace folder
|
||||
.vscode
|
||||
|
||||
# git stackdumps
|
||||
*.stackdump
|
||||
|
||||
# diffs
|
||||
diff.txt
|
||||
|
||||
# build destination
|
||||
dest
|
||||
build/closure/closure_compiled_binary.js
|
||||
|
||||
# spriting artifacts
|
||||
src/img/icons.png
|
||||
src/img/icons@2x.png
|
||||
src/css/icons.css
|
||||
|
||||
# plato report directory
|
||||
report
|
||||
|
||||
# marked as private
|
||||
*.private.*
|
||||
*.stackdump
|
@ -1,3 +0,0 @@
|
||||
node_modules/
|
||||
test/
|
||||
|
10
.travis.yml
@ -1,10 +0,0 @@
|
||||
language: node_js
|
||||
node_js:
|
||||
- "7.4.0"
|
||||
before_install:
|
||||
- npm update -g npm
|
||||
- npm install -g grunt-cli
|
||||
before_script:
|
||||
- phantomjs --version
|
||||
- casperjs --version
|
||||
sudo: false
|
349
Gruntfile.js
@ -1,349 +0,0 @@
|
||||
module.exports = function(grunt) {
|
||||
|
||||
// Update this variable if you don't want or can't serve on localhost
|
||||
var hostname = 'localhost';
|
||||
|
||||
var PORT = {
|
||||
PROD : 9001,
|
||||
DEV : 9901,
|
||||
TEST : 9991
|
||||
};
|
||||
|
||||
// create a version based on the build timestamp
|
||||
var dateFormat = require('dateformat');
|
||||
var version = '-' + dateFormat(new Date(), "yyyy-mm-dd-hh-MM");
|
||||
var releaseVersion = require('./package.json').version;
|
||||
|
||||
/**
|
||||
* Helper to prefix all strings in provided array with the provided path
|
||||
*/
|
||||
var prefixPaths = function (paths, prefix) {
|
||||
return paths.map(function (path) {
|
||||
return prefix + path;
|
||||
});
|
||||
};
|
||||
|
||||
// get the list of scripts paths to include
|
||||
var scriptPaths = require('./src/piskel-script-list.js').scripts;
|
||||
var piskelScripts = prefixPaths(scriptPaths, "src/").filter(function (path) {
|
||||
return path.indexOf('devtools') === -1;
|
||||
});
|
||||
|
||||
// get the list of styles paths to include
|
||||
var stylePaths = require('./src/piskel-style-list.js').styles;
|
||||
var piskelStyles = prefixPaths(stylePaths, "src/");
|
||||
|
||||
// Casper JS tests
|
||||
var casperjsOptions = [
|
||||
'--baseUrl=http://' + hostname + ':' + PORT.TEST,
|
||||
'--mode=?debug',
|
||||
'--verbose=false',
|
||||
'--includes=test/casperjs/integration/include.js',
|
||||
'--log-level=info',
|
||||
'--print-command=false',
|
||||
'--print-file-paths=true',
|
||||
];
|
||||
|
||||
var integrationTestPaths = require('./test/casperjs/integration/IntegrationSuite.js').tests;
|
||||
var integrationTests = prefixPaths(integrationTestPaths, "test/casperjs/integration/");
|
||||
|
||||
var getConnectConfig = function (base, port, host, open) {
|
||||
return {
|
||||
options: {
|
||||
port: port,
|
||||
hostname : host,
|
||||
base: base,
|
||||
open: open
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
// load all grunt tasks
|
||||
require('load-grunt-tasks')(grunt);
|
||||
|
||||
grunt.initConfig({
|
||||
clean: {
|
||||
all: ['dest', 'src/img/icons.png', 'src/css/icons.css'],
|
||||
prod: ['dest/prod', 'dest/tmp'],
|
||||
desktop: ['dest/desktop', 'dest/tmp'],
|
||||
dev: ['dest/dev', 'dest/tmp']
|
||||
},
|
||||
|
||||
/**
|
||||
* STYLE CHECKS
|
||||
*/
|
||||
|
||||
leadingIndent : {
|
||||
options: {
|
||||
indentation : "spaces"
|
||||
},
|
||||
css : ['src/css/**/*.css']
|
||||
},
|
||||
|
||||
eslint: {
|
||||
files: [
|
||||
// Includes
|
||||
'src/js/**/*.js',
|
||||
// Exludes
|
||||
// TODO: remove this (for now we still get warnings from the lib folder)
|
||||
'!src/js/**/lib/**/*.js'
|
||||
],
|
||||
options: {
|
||||
fix: grunt.option('fix') // this will get params from the flags
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* SERVERS, BROWSER LAUNCHERS
|
||||
*/
|
||||
|
||||
connect: {
|
||||
prod: getConnectConfig('dest/prod', PORT.PROD, hostname, true),
|
||||
test: getConnectConfig(['dest/dev', 'test'], PORT.TEST, hostname, false),
|
||||
dev: getConnectConfig(['dest/dev', 'test'], PORT.DEV, hostname, 'http://' + hostname + ':' + PORT.DEV + '/?debug')
|
||||
},
|
||||
|
||||
watch: {
|
||||
prod: {
|
||||
files: ['src/**/*.*'],
|
||||
tasks: ['build'],
|
||||
options: {
|
||||
spawn: false
|
||||
}
|
||||
},
|
||||
dev: {
|
||||
files: ['src/**/*.*'],
|
||||
tasks: ['build-dev'],
|
||||
options: {
|
||||
spawn: false
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* BUILD STEPS
|
||||
*/
|
||||
|
||||
sprite:{
|
||||
all : {
|
||||
src: 'src/img/icons/**/*.png',
|
||||
retinaSrcFilter: 'src/img/icons/**/*@2x.png',
|
||||
dest: 'src/img/icons.png',
|
||||
retinaDest: 'src/img/icons@2x.png',
|
||||
destCss: 'src/css/icons.css'
|
||||
}
|
||||
},
|
||||
|
||||
concat : {
|
||||
js : {
|
||||
options : {
|
||||
separator : ';'
|
||||
},
|
||||
src : piskelScripts,
|
||||
dest : 'dest/prod/js/piskel-packaged' + version + '.js'
|
||||
},
|
||||
css : {
|
||||
src : piskelStyles,
|
||||
dest : 'dest/tmp/css/piskel-style-packaged' + version + '.css'
|
||||
}
|
||||
},
|
||||
|
||||
uglify : {
|
||||
options : {
|
||||
mangle : true
|
||||
},
|
||||
js : {
|
||||
files : {
|
||||
'dest/tmp/js/piskel-packaged-min.js' : ['dest/prod/js/piskel-packaged' + version + '.js']
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
includereplace: {
|
||||
all: {
|
||||
src: 'src/index.html',
|
||||
dest: 'dest/tmp/index.html',
|
||||
options : {
|
||||
globals : {
|
||||
'version' : version,
|
||||
'releaseVersion' : releaseVersion
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
replace: {
|
||||
// main-partial.html is used when embedded in piskelapp.com
|
||||
mainPartial: {
|
||||
options: {
|
||||
patterns: [{
|
||||
match: /^(.|[\r\n])*<!--body-main-start-->/,
|
||||
replacement: "{% raw %}",
|
||||
description : "Remove everything before body-main-start comment"
|
||||
},{
|
||||
match: /<!--body-main-end-->(.|[\r\n])*$/,
|
||||
replacement: "{% endraw %}",
|
||||
description : "Remove everything after body-main-end comment"
|
||||
},{
|
||||
match: /([\r\n]) /g,
|
||||
replacement: "$1",
|
||||
description : "Decrease indentation by one"
|
||||
}
|
||||
]
|
||||
},
|
||||
files: [
|
||||
// src/index.html should already have been moved by the includereplace task
|
||||
{src: ['dest/tmp/index.html'], dest: 'dest/prod/piskelapp-partials/main-partial.html'}
|
||||
]
|
||||
},
|
||||
|
||||
css: {
|
||||
options: {
|
||||
patterns: [{
|
||||
match: /var\(--highlight-color\)/g,
|
||||
replacement: "gold",
|
||||
}]
|
||||
},
|
||||
files: [{
|
||||
src: ['dest/tmp/css/piskel-style-packaged' + version + '.css'],
|
||||
dest: 'dest/prod/css/piskel-style-packaged' + version + '.css'
|
||||
}]
|
||||
}
|
||||
},
|
||||
|
||||
copy: {
|
||||
prod: {
|
||||
files: [
|
||||
// dest/js/piskel-packaged-min.js should have been created by the uglify task
|
||||
{src: ['dest/tmp/js/piskel-packaged-min.js'], dest: 'dest/prod/js/piskel-packaged-min' + version + '.js'},
|
||||
{src: ['dest/tmp/index.html'], dest: 'dest/prod/index.html'},
|
||||
{src: ['src/logo.png'], dest: 'dest/prod/logo.png'},
|
||||
{src: ['src/js/lib/gif/gif.ie.worker.js'], dest: 'dest/prod/js/lib/gif/gif.ie.worker.js'},
|
||||
{expand: true, src: ['img/**'], cwd: 'src/', dest: 'dest/prod/', filter: 'isFile'},
|
||||
{expand: true, src: ['css/fonts/**'], cwd: 'src/', dest: 'dest/prod/', filter: 'isFile'}
|
||||
]
|
||||
},
|
||||
dev: {
|
||||
files: [
|
||||
// in dev copy everything to dest/dev
|
||||
{src: ['dest/tmp/index.html'], dest: 'dest/dev/index.html'},
|
||||
{src: ['src/piskel-script-list.js'], dest: 'dest/dev/piskel-script-list.js'},
|
||||
{src: ['src/piskel-style-list.js'], dest: 'dest/dev/piskel-style-list.js'},
|
||||
{expand: true, src: ['js/**'], cwd: 'src/', dest: 'dest/dev/', filter: 'isFile'},
|
||||
{expand: true, src: ['css/**'], cwd: 'src/', dest: 'dest/dev/', filter: 'isFile'},
|
||||
{expand: true, src: ['img/**'], cwd: 'src/', dest: 'dest/dev/', filter: 'isFile'},
|
||||
]
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* TESTING
|
||||
*/
|
||||
|
||||
karma: {
|
||||
unit: {
|
||||
configFile: 'karma.conf.js'
|
||||
}
|
||||
},
|
||||
|
||||
casperjs : {
|
||||
drawing : {
|
||||
files : {
|
||||
src: ['test/casperjs/DrawingTest.js']
|
||||
},
|
||||
options : {
|
||||
casperjsOptions: casperjsOptions
|
||||
}
|
||||
},
|
||||
integration : {
|
||||
files : {
|
||||
src: integrationTests
|
||||
},
|
||||
options : {
|
||||
casperjsOptions: casperjsOptions
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* DESKTOP BUILDS
|
||||
*/
|
||||
|
||||
nwjs: {
|
||||
windows : {
|
||||
options: {
|
||||
downloadUrl: 'https://dl.nwjs.io/',
|
||||
version : "0.19.4",
|
||||
build_dir: './dest/desktop/', // destination folder of releases.
|
||||
win: true,
|
||||
linux32: true,
|
||||
linux64: true,
|
||||
flavor: "normal",
|
||||
},
|
||||
src: ['./dest/prod/**/*', "./package.json", "!./dest/desktop/"]
|
||||
},
|
||||
macos : {
|
||||
options: {
|
||||
downloadUrl: 'https://dl.nwjs.io/',
|
||||
osx64: true,
|
||||
version : "0.19.4",
|
||||
build_dir: './dest/desktop/',
|
||||
flavor: "normal",
|
||||
},
|
||||
src: ['./dest/prod/**/*', "./package.json", "!./dest/desktop/"]
|
||||
},
|
||||
macos_old : {
|
||||
options: {
|
||||
downloadUrl: 'https://dl.nwjs.io/',
|
||||
osx64: true,
|
||||
version : "0.12.3",
|
||||
build_dir: './dest/desktop/old',
|
||||
flavor: "normal",
|
||||
},
|
||||
src: ['./dest/prod/**/*', "./package.json", "!./dest/desktop/"]
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
// TEST TASKS
|
||||
// Run linting
|
||||
grunt.registerTask('lint', ['eslint', 'leadingIndent:css']);
|
||||
// Run unit-tests
|
||||
grunt.registerTask('unit-test', ['karma']);
|
||||
// Run integration tests
|
||||
grunt.registerTask('integration-test', ['build-dev', 'connect:test', 'casperjs:integration']);
|
||||
// Run drawing tests
|
||||
grunt.registerTask('drawing-test', ['build-dev', 'connect:test', 'casperjs:drawing']);
|
||||
// Run linting, unit tests, drawing tests and integration tests
|
||||
grunt.registerTask('test', ['lint', 'unit-test', 'build-dev', 'connect:test', 'casperjs:drawing', 'casperjs:integration']);
|
||||
|
||||
// Run the tests, even if the linting fails
|
||||
grunt.registerTask('test-nolint', ['unit-test', 'build-dev', 'connect:test', 'casperjs:drawing', 'casperjs:integration']);
|
||||
|
||||
// Used by optional precommit hook
|
||||
grunt.registerTask('precommit', ['test']);
|
||||
|
||||
// BUILD TASKS
|
||||
grunt.registerTask('build-index.html', ['includereplace']);
|
||||
grunt.registerTask('merge-statics', ['concat:js', 'concat:css', 'uglify']);
|
||||
grunt.registerTask('build', ['clean:prod', 'sprite', 'merge-statics', 'build-index.html', 'replace:mainPartial', 'replace:css', 'copy:prod']);
|
||||
grunt.registerTask('build-dev', ['clean:dev', 'sprite', 'build-index.html', 'copy:dev']);
|
||||
grunt.registerTask('desktop', ['clean:desktop', 'default', 'nwjs:windows']);
|
||||
grunt.registerTask('desktop-mac', ['clean:desktop', 'default', 'nwjs:macos']);
|
||||
grunt.registerTask('desktop-mac-old', ['clean:desktop', 'default', 'replace:desktop', 'nwjs:macos_old']);
|
||||
|
||||
// SERVER TASKS
|
||||
// Start webserver and watch for changes
|
||||
grunt.registerTask('serve', ['build', 'connect:prod', 'watch:prod']);
|
||||
// Start webserver on src folder, in debug mode
|
||||
grunt.registerTask('play', ['build-dev', 'connect:dev', 'watch:dev']);
|
||||
|
||||
// ALIASES, kept for backward compatibility
|
||||
grunt.registerTask('serve-debug', ['play']);
|
||||
grunt.registerTask('serve-dev', ['play']);
|
||||
grunt.registerTask('test-travis', ['test']);
|
||||
grunt.registerTask('test-local', ['test']);
|
||||
|
||||
// Default task
|
||||
grunt.registerTask('default', ['lint', 'build']);
|
||||
};
|
202
LICENSE
@ -1,202 +0,0 @@
|
||||
|
||||
Apache License
|
||||
Version 2.0, January 2004
|
||||
http://www.apache.org/licenses/
|
||||
|
||||
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
||||
|
||||
1. Definitions.
|
||||
|
||||
"License" shall mean the terms and conditions for use, reproduction,
|
||||
and distribution as defined by Sections 1 through 9 of this document.
|
||||
|
||||
"Licensor" shall mean the copyright owner or entity authorized by
|
||||
the copyright owner that is granting the License.
|
||||
|
||||
"Legal Entity" shall mean the union of the acting entity and all
|
||||
other entities that control, are controlled by, or are under common
|
||||
control with that entity. For the purposes of this definition,
|
||||
"control" means (i) the power, direct or indirect, to cause the
|
||||
direction or management of such entity, whether by contract or
|
||||
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
||||
outstanding shares, or (iii) beneficial ownership of such entity.
|
||||
|
||||
"You" (or "Your") shall mean an individual or Legal Entity
|
||||
exercising permissions granted by this License.
|
||||
|
||||
"Source" form shall mean the preferred form for making modifications,
|
||||
including but not limited to software source code, documentation
|
||||
source, and configuration files.
|
||||
|
||||
"Object" form shall mean any form resulting from mechanical
|
||||
transformation or translation of a Source form, including but
|
||||
not limited to compiled object code, generated documentation,
|
||||
and conversions to other media types.
|
||||
|
||||
"Work" shall mean the work of authorship, whether in Source or
|
||||
Object form, made available under the License, as indicated by a
|
||||
copyright notice that is included in or attached to the work
|
||||
(an example is provided in the Appendix below).
|
||||
|
||||
"Derivative Works" shall mean any work, whether in Source or Object
|
||||
form, that is based on (or derived from) the Work and for which the
|
||||
editorial revisions, annotations, elaborations, or other modifications
|
||||
represent, as a whole, an original work of authorship. For the purposes
|
||||
of this License, Derivative Works shall not include works that remain
|
||||
separable from, or merely link (or bind by name) to the interfaces of,
|
||||
the Work and Derivative Works thereof.
|
||||
|
||||
"Contribution" shall mean any work of authorship, including
|
||||
the original version of the Work and any modifications or additions
|
||||
to that Work or Derivative Works thereof, that is intentionally
|
||||
submitted to Licensor for inclusion in the Work by the copyright owner
|
||||
or by an individual or Legal Entity authorized to submit on behalf of
|
||||
the copyright owner. For the purposes of this definition, "submitted"
|
||||
means any form of electronic, verbal, or written communication sent
|
||||
to the Licensor or its representatives, including but not limited to
|
||||
communication on electronic mailing lists, source code control systems,
|
||||
and issue tracking systems that are managed by, or on behalf of, the
|
||||
Licensor for the purpose of discussing and improving the Work, but
|
||||
excluding communication that is conspicuously marked or otherwise
|
||||
designated in writing by the copyright owner as "Not a Contribution."
|
||||
|
||||
"Contributor" shall mean Licensor and any individual or Legal Entity
|
||||
on behalf of whom a Contribution has been received by Licensor and
|
||||
subsequently incorporated within the Work.
|
||||
|
||||
2. Grant of Copyright License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
copyright license to reproduce, prepare Derivative Works of,
|
||||
publicly display, publicly perform, sublicense, and distribute the
|
||||
Work and such Derivative Works in Source or Object form.
|
||||
|
||||
3. Grant of Patent License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
(except as stated in this section) patent license to make, have made,
|
||||
use, offer to sell, sell, import, and otherwise transfer the Work,
|
||||
where such license applies only to those patent claims licensable
|
||||
by such Contributor that are necessarily infringed by their
|
||||
Contribution(s) alone or by combination of their Contribution(s)
|
||||
with the Work to which such Contribution(s) was submitted. If You
|
||||
institute patent litigation against any entity (including a
|
||||
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
||||
or a Contribution incorporated within the Work constitutes direct
|
||||
or contributory patent infringement, then any patent licenses
|
||||
granted to You under this License for that Work shall terminate
|
||||
as of the date such litigation is filed.
|
||||
|
||||
4. Redistribution. You may reproduce and distribute copies of the
|
||||
Work or Derivative Works thereof in any medium, with or without
|
||||
modifications, and in Source or Object form, provided that You
|
||||
meet the following conditions:
|
||||
|
||||
(a) You must give any other recipients of the Work or
|
||||
Derivative Works a copy of this License; and
|
||||
|
||||
(b) You must cause any modified files to carry prominent notices
|
||||
stating that You changed the files; and
|
||||
|
||||
(c) You must retain, in the Source form of any Derivative Works
|
||||
that You distribute, all copyright, patent, trademark, and
|
||||
attribution notices from the Source form of the Work,
|
||||
excluding those notices that do not pertain to any part of
|
||||
the Derivative Works; and
|
||||
|
||||
(d) If the Work includes a "NOTICE" text file as part of its
|
||||
distribution, then any Derivative Works that You distribute must
|
||||
include a readable copy of the attribution notices contained
|
||||
within such NOTICE file, excluding those notices that do not
|
||||
pertain to any part of the Derivative Works, in at least one
|
||||
of the following places: within a NOTICE text file distributed
|
||||
as part of the Derivative Works; within the Source form or
|
||||
documentation, if provided along with the Derivative Works; or,
|
||||
within a display generated by the Derivative Works, if and
|
||||
wherever such third-party notices normally appear. The contents
|
||||
of the NOTICE file are for informational purposes only and
|
||||
do not modify the License. You may add Your own attribution
|
||||
notices within Derivative Works that You distribute, alongside
|
||||
or as an addendum to the NOTICE text from the Work, provided
|
||||
that such additional attribution notices cannot be construed
|
||||
as modifying the License.
|
||||
|
||||
You may add Your own copyright statement to Your modifications and
|
||||
may provide additional or different license terms and conditions
|
||||
for use, reproduction, or distribution of Your modifications, or
|
||||
for any such Derivative Works as a whole, provided Your use,
|
||||
reproduction, and distribution of the Work otherwise complies with
|
||||
the conditions stated in this License.
|
||||
|
||||
5. Submission of Contributions. Unless You explicitly state otherwise,
|
||||
any Contribution intentionally submitted for inclusion in the Work
|
||||
by You to the Licensor shall be under the terms and conditions of
|
||||
this License, without any additional terms or conditions.
|
||||
Notwithstanding the above, nothing herein shall supersede or modify
|
||||
the terms of any separate license agreement you may have executed
|
||||
with Licensor regarding such Contributions.
|
||||
|
||||
6. Trademarks. This License does not grant permission to use the trade
|
||||
names, trademarks, service marks, or product names of the Licensor,
|
||||
except as required for reasonable and customary use in describing the
|
||||
origin of the Work and reproducing the content of the NOTICE file.
|
||||
|
||||
7. Disclaimer of Warranty. Unless required by applicable law or
|
||||
agreed to in writing, Licensor provides the Work (and each
|
||||
Contributor provides its Contributions) on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
||||
implied, including, without limitation, any warranties or conditions
|
||||
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
||||
PARTICULAR PURPOSE. You are solely responsible for determining the
|
||||
appropriateness of using or redistributing the Work and assume any
|
||||
risks associated with Your exercise of permissions under this License.
|
||||
|
||||
8. Limitation of Liability. In no event and under no legal theory,
|
||||
whether in tort (including negligence), contract, or otherwise,
|
||||
unless required by applicable law (such as deliberate and grossly
|
||||
negligent acts) or agreed to in writing, shall any Contributor be
|
||||
liable to You for damages, including any direct, indirect, special,
|
||||
incidental, or consequential damages of any character arising as a
|
||||
result of this License or out of the use or inability to use the
|
||||
Work (including but not limited to damages for loss of goodwill,
|
||||
work stoppage, computer failure or malfunction, or any and all
|
||||
other commercial damages or losses), even if such Contributor
|
||||
has been advised of the possibility of such damages.
|
||||
|
||||
9. Accepting Warranty or Additional Liability. While redistributing
|
||||
the Work or Derivative Works thereof, You may choose to offer,
|
||||
and charge a fee for, acceptance of support, warranty, indemnity,
|
||||
or other liability obligations and/or rights consistent with this
|
||||
License. However, in accepting such obligations, You may act only
|
||||
on Your own behalf and on Your sole responsibility, not on behalf
|
||||
of any other Contributor, and only if You agree to indemnify,
|
||||
defend, and hold each Contributor harmless for any liability
|
||||
incurred by, or claims asserted against, such Contributor by reason
|
||||
of your accepting any such warranty or additional liability.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
APPENDIX: How to apply the Apache License to your work.
|
||||
|
||||
To apply the Apache License to your work, attach the following
|
||||
boilerplate notice, with the fields enclosed by brackets "[]"
|
||||
replaced with your own identifying information. (Don't include
|
||||
the brackets!) The text should be enclosed in the appropriate
|
||||
comment syntax for the file format. We also recommend that a
|
||||
file or class name and description of purpose be included on the
|
||||
same "printed page" as the copyright notice for easier
|
||||
identification within third-party archives.
|
||||
|
||||
Copyright [yyyy] [name of copyright owner]
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
71
README.md
@ -1,71 +0,0 @@
|
||||
Piskel
|
||||
======
|
||||
|
||||
[](https://travis-ci.org/piskelapp/piskel) [](https://gruntjs.com/)
|
||||
|
||||
Piskel is an easy-to-use sprite editor. It can be used to create game sprites, animations, pixel-art...
|
||||
It is the editor used in **[piskelapp.com](https://www.piskelapp.com)**.
|
||||
|
||||
<img
|
||||
src="https://screenletstore.appspot.com/img/95aaa0f0-37a4-11e7-a652-7b8128ce3e3b.png"
|
||||
title="Piskel editor screenshot"
|
||||
width="500">
|
||||
|
||||
## About Piskel
|
||||
|
||||
### Built with
|
||||
|
||||
The Piskel editor is purely built in **JavaScript, HTML and CSS**.
|
||||
|
||||
We also use the following **libraries** :
|
||||
* [spectrum](https://github.com/bgrins/spectrum) : awesome standalone colorpicker
|
||||
* [gifjs](https://jnordberg.github.io/gif.js/) : generate animated GIFs in javascript, using webworkers
|
||||
* [supergif](https://github.com/buzzfeed/libgif-js) : modified version of SuperGif to parse and import GIFs
|
||||
* [jszip](https://github.com/Stuk/jszip) : create, read and edit .zip files with Javascript
|
||||
* [canvas-toBlob](https://github.com/eligrey/canvas-toBlob.js/) : shim for canvas toBlob
|
||||
* [jquery](https://jquery.com/) : used sporadically in the application
|
||||
* [bootstrap-tooltip](https://getbootstrap.com/javascript/#tooltips) : nice tooltips
|
||||
|
||||
As well as some **icons** from the [Noun Project](https://thenounproject.com/) :
|
||||
* Folder by Simple Icons from The Noun Project
|
||||
* (and probably one or two others)
|
||||
|
||||
### Browser Support
|
||||
|
||||
Piskel supports the following browsers:
|
||||
* **Chrome** (latest)
|
||||
* **Firefox** (latest)
|
||||
* **Edge** (latest)
|
||||
* **Internet Explorer** 11
|
||||
|
||||
### Mobile/Tablets
|
||||
|
||||
There is no support for mobile.
|
||||
|
||||
### Offline builds
|
||||
|
||||
Offline builds are available. More details in the [dedicated wiki page](https://github.com/piskelapp/piskel/wiki/Desktop-applications).
|
||||
|
||||
## Contributing ?
|
||||
|
||||
Help is always welcome !
|
||||
|
||||
* **Issues** : Found a problem when using the application, want to request a feature, [open an issue](https://github.com/piskelapp/piskel/issues).
|
||||
* **Development** : Have a look at the [wiki](https://github.com/piskelapp/piskel/wiki) to set up the development environment
|
||||
|
||||
## License
|
||||
|
||||
Copyright 2017 Julian Descottes
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
|
32
RELEASE.md
@ -1,32 +0,0 @@
|
||||
# Release instructions
|
||||
|
||||
- retrieve source code and dependencies
|
||||
- clone piskel `git clone https://github.com/piskelapp/piskel`
|
||||
- clone piskel website `git clone https://github.com/piskelapp/piskel-website`
|
||||
- download the appengine SDK for python at [this url](https://cloud.google.com/appengine/docs/standard/python/download). It seems recent versions don't work for me on Windows. [GoogleAppEngine-1.9.67.msi](https://storage.cloud.google.com/appengine-sdks/featured/GoogleAppEngine-1.9.67.msi?_ga=2.6838962.-1257793585.1543157659) looks ok...
|
||||
- prepare the release
|
||||
- in `piskel-website` clone, checkout the `master` branch, not the `release`. The release branch is similar to the master branch, except it doesn't ignore the statics files coming from the `piskel` project. The idea is that we can easily checkout the release branch to do a new release, without having to rebuild piskel, in case nothing changed in piskel itself. We will switch to the release branch when we perform the final release.
|
||||
- in `piskel` clone, create a new branch for the release `git checkout -b vX.Y`
|
||||
- build and copy piskel to piskel-website (assumes the clones are in the same folder) `grunt && node bin/copy-to-piskel-website.js`
|
||||
- local test
|
||||
- start piskel-website in the Google app engine launcher, test manually the update
|
||||
- if any issue is detected create a commit to fix it (on the `vX.Y` branch) and push it.
|
||||
|
||||
- beta test
|
||||
- check the version in app.yaml is set to 'beta'. For historical reasons, alpha is the "production" version, while beta is the ... beta version. Don't ask.
|
||||
- in the google app engine launcher, deploy this version.
|
||||
- go to https://beta-dot-piskel-app.appspot.com and test (while this is not production frontend, it shares the same database, so be careful with what you create and delete)
|
||||
- if any issue is detected create a commit to fix it (on `master`) and push it.
|
||||
- check caches...
|
||||
- If any icon was modified or any script of piskel-website was modified, there's no nice way to clean the cache on each release... so we just put a time stamp in the requests. eg `background-image: url(../img/icons@2x.png?20181125);` or `<script type="text/javascript" src="/static/js/piskel-animated-preview.js?20181124"></script>`. Erk.
|
||||
- finalize the release
|
||||
- in `piskel` update version in package.json. Remove the "-SNAPSHOT" at the end and commit the change, with a commit message such as `release: bump version to vX.Y`.
|
||||
- in `piskel-website` checkout the `release` branch. Rebase it on master (that's pretty bad, we should probably cherry pick all the changes between the two branches...)
|
||||
- once again build and copy piskel to piskel-website
|
||||
- in `piskel-website` run `git status` to check that there are a bunch of changes to commit. (test locally again if you are paranoid)
|
||||
- in `piskel-website` commit the current changes with a commit message such as `update statics for release vX.Y`
|
||||
- Check that the version in app.yaml is now set to alpha. Deploy. Pray.
|
||||
- post release
|
||||
- in piskel-website push the release branch to github
|
||||
- in piskel add a last commit to update the version in package.json to update the version to `vX+1.0-SNAPSHOT`
|
||||
- create a tag on github
|
@ -1,84 +0,0 @@
|
||||
const rmdir = require('rmdir');
|
||||
const path = require('path');
|
||||
const fs = require('fs');
|
||||
const fse = require('fs-extra');
|
||||
|
||||
const PISKEL_PATH = path.resolve(__dirname, '..');
|
||||
const PISKELAPP_PATH = path.resolve(__dirname, '../../piskel-website');
|
||||
|
||||
var pjson = require('../package.json');
|
||||
|
||||
// Callbacks sorted by call sequence.
|
||||
function onCopy(err) {
|
||||
if (err) {
|
||||
console.error('Failed to copy static files...');
|
||||
return console.error(err);
|
||||
}
|
||||
|
||||
console.log('Copied static files to piskel-website...');
|
||||
let previousPartialPath = path.resolve(PISKELAPP_PATH, 'templates/editor/main-partial.html');
|
||||
fs.access(previousPartialPath, fs.constants.F_OK, function (err) {
|
||||
if (err) {
|
||||
// File does not exit, call next step directly.
|
||||
console.error('Previous main partial doesn\'t exist yet.');
|
||||
onDeletePreviousPartial();
|
||||
} else {
|
||||
// File exists, try to delete it before moving on.
|
||||
fs.unlink(previousPartialPath, onDeletePreviousPartial);
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
function onDeletePreviousPartial(err) {
|
||||
if (err) {
|
||||
console.error('Failed to delete previous main partial...');
|
||||
return console.error(err);
|
||||
}
|
||||
|
||||
console.log('Previous main partial deleted...');
|
||||
fse.copy(
|
||||
path.resolve(PISKELAPP_PATH, "static/editor/piskelapp-partials/main-partial.html"),
|
||||
path.resolve(PISKELAPP_PATH, "templates/editor/main-partial.html"),
|
||||
onCopyNewPartial
|
||||
);
|
||||
}
|
||||
|
||||
function onCopyNewPartial(err) {
|
||||
if (err) {
|
||||
console.error('Failed to delete previous main partial...');
|
||||
return console.error(err);
|
||||
}
|
||||
|
||||
console.log('Main partial copied...');
|
||||
rmdir(
|
||||
path.resolve(PISKELAPP_PATH, "static/editor/piskelapp-partials/"),
|
||||
onDeleteTempPartial
|
||||
);
|
||||
}
|
||||
|
||||
function onDeleteTempPartial(err) {
|
||||
if (err) {
|
||||
console.error('Failed to delete temporary main partial...');
|
||||
return console.error(err);
|
||||
}
|
||||
|
||||
console.log('Temporary main partial deleted...');
|
||||
|
||||
fs.writeFile(path.resolve(PISKELAPP_PATH, "static/editor/VERSION"), pjson.version, onVersionFileCreated);
|
||||
}
|
||||
|
||||
function onVersionFileCreated(err) {
|
||||
if (err) {
|
||||
console.error('Failed to create temporary main partial...');
|
||||
return console.error(err);
|
||||
}
|
||||
|
||||
console.log('Version file created...');
|
||||
console.log('Finished!');
|
||||
}
|
||||
|
||||
fse.copy(
|
||||
path.resolve(PISKEL_PATH, "dest/prod"),
|
||||
path.resolve(PISKELAPP_PATH, "static/editor"),
|
||||
onCopy
|
||||
);
|
Before Width: | Height: | Size: 8.6 KiB After Width: | Height: | Size: 8.6 KiB |
Before Width: | Height: | Size: 4.7 KiB After Width: | Height: | Size: 4.7 KiB |
4293
chromebook_alert/css/piskel-style-packaged-2017-07-17-12-59.css
Normal file
Before Width: | Height: | Size: 222 B After Width: | Height: | Size: 222 B |
Before Width: | Height: | Size: 255 B After Width: | Height: | Size: 255 B |
Before Width: | Height: | Size: 255 B After Width: | Height: | Size: 255 B |
Before Width: | Height: | Size: 254 B After Width: | Height: | Size: 254 B |
Before Width: | Height: | Size: 766 B After Width: | Height: | Size: 766 B |
Before Width: | Height: | Size: 209 B After Width: | Height: | Size: 209 B |
Before Width: | Height: | Size: 702 B After Width: | Height: | Size: 702 B |
Before Width: | Height: | Size: 543 B After Width: | Height: | Size: 543 B |
Before Width: | Height: | Size: 656 B After Width: | Height: | Size: 656 B |
Before Width: | Height: | Size: 672 B After Width: | Height: | Size: 672 B |
Before Width: | Height: | Size: 606 B After Width: | Height: | Size: 606 B |
Before Width: | Height: | Size: 557 B After Width: | Height: | Size: 557 B |
Before Width: | Height: | Size: 707 B After Width: | Height: | Size: 707 B |
Before Width: | Height: | Size: 450 B After Width: | Height: | Size: 450 B |
Before Width: | Height: | Size: 660 B After Width: | Height: | Size: 660 B |
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 617 B After Width: | Height: | Size: 617 B |
Before Width: | Height: | Size: 603 B After Width: | Height: | Size: 603 B |
Before Width: | Height: | Size: 570 B After Width: | Height: | Size: 570 B |
Before Width: | Height: | Size: 177 B After Width: | Height: | Size: 177 B |
BIN
chromebook_alert/img/icons.png
Normal file
After Width: | Height: | Size: 12 KiB |
Before Width: | Height: | Size: 340 B After Width: | Height: | Size: 340 B |
Before Width: | Height: | Size: 570 B After Width: | Height: | Size: 570 B |
Before Width: | Height: | Size: 565 B After Width: | Height: | Size: 565 B |
Before Width: | Height: | Size: 960 B After Width: | Height: | Size: 960 B |
Before Width: | Height: | Size: 446 B After Width: | Height: | Size: 446 B |
Before Width: | Height: | Size: 851 B After Width: | Height: | Size: 851 B |
Before Width: | Height: | Size: 324 B After Width: | Height: | Size: 324 B |
Before Width: | Height: | Size: 537 B After Width: | Height: | Size: 537 B |
Before Width: | Height: | Size: 387 B After Width: | Height: | Size: 387 B |
Before Width: | Height: | Size: 664 B After Width: | Height: | Size: 664 B |
Before Width: | Height: | Size: 210 B After Width: | Height: | Size: 210 B |
Before Width: | Height: | Size: 262 B After Width: | Height: | Size: 262 B |
Before Width: | Height: | Size: 319 B After Width: | Height: | Size: 319 B |
Before Width: | Height: | Size: 539 B After Width: | Height: | Size: 539 B |
Before Width: | Height: | Size: 301 B After Width: | Height: | Size: 301 B |
Before Width: | Height: | Size: 367 B After Width: | Height: | Size: 367 B |
Before Width: | Height: | Size: 246 B After Width: | Height: | Size: 246 B |
Before Width: | Height: | Size: 357 B After Width: | Height: | Size: 357 B |
Before Width: | Height: | Size: 589 B After Width: | Height: | Size: 589 B |
Before Width: | Height: | Size: 1016 B After Width: | Height: | Size: 1016 B |
Before Width: | Height: | Size: 668 B After Width: | Height: | Size: 668 B |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 587 B After Width: | Height: | Size: 587 B |
Before Width: | Height: | Size: 1008 B After Width: | Height: | Size: 1008 B |
Before Width: | Height: | Size: 392 B After Width: | Height: | Size: 392 B |
Before Width: | Height: | Size: 656 B After Width: | Height: | Size: 656 B |
Before Width: | Height: | Size: 381 B After Width: | Height: | Size: 381 B |
Before Width: | Height: | Size: 652 B After Width: | Height: | Size: 652 B |
Before Width: | Height: | Size: 495 B After Width: | Height: | Size: 495 B |
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 563 B After Width: | Height: | Size: 563 B |
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 2.8 KiB After Width: | Height: | Size: 2.8 KiB |
Before Width: | Height: | Size: 245 B After Width: | Height: | Size: 245 B |
Before Width: | Height: | Size: 393 B After Width: | Height: | Size: 393 B |
Before Width: | Height: | Size: 524 B After Width: | Height: | Size: 524 B |
Before Width: | Height: | Size: 963 B After Width: | Height: | Size: 963 B |
Before Width: | Height: | Size: 827 B After Width: | Height: | Size: 827 B |
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 690 B After Width: | Height: | Size: 690 B |
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 547 B After Width: | Height: | Size: 547 B |
Before Width: | Height: | Size: 1015 B After Width: | Height: | Size: 1015 B |
Before Width: | Height: | Size: 741 B After Width: | Height: | Size: 741 B |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 670 B After Width: | Height: | Size: 670 B |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 276 B After Width: | Height: | Size: 276 B |
Before Width: | Height: | Size: 425 B After Width: | Height: | Size: 425 B |
Before Width: | Height: | Size: 245 B After Width: | Height: | Size: 245 B |
Before Width: | Height: | Size: 395 B After Width: | Height: | Size: 395 B |
Before Width: | Height: | Size: 580 B After Width: | Height: | Size: 580 B |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 802 B After Width: | Height: | Size: 802 B |
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 744 B After Width: | Height: | Size: 744 B |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 297 B After Width: | Height: | Size: 297 B |