smartphoto
Advanced tools
Comparing version 0.2.2 to 0.2.3
{ | ||
"name": "smartphoto", | ||
"version": "0.2.2", | ||
"version": "0.2.3", | ||
"description": "smartphoto", | ||
@@ -18,3 +18,6 @@ "homepage": "http://developer.a-blogcms.jp", | ||
"sync": "browser-sync start --server './' --files './js/*.js' './css/*.css' --startPath '/examples/jquery.html'", | ||
"start": "npm-run-all -p watch:js watch:sass sync" | ||
"start": "npm-run-all -p watch:js watch:sass sync", | ||
"patch": "npm version patch && node ./tools/index.js", | ||
"minor": "npm version minor && node ./tools/index.js", | ||
"major": "npm version major && node ./tools/index.js" | ||
}, | ||
@@ -39,3 +42,6 @@ "author": "appleple", | ||
"uglify-js": "^2.7.5", | ||
"watchify": "^3.9.0" | ||
"watchify": "^3.9.0", | ||
"node-cmd": "^2.0.0", | ||
"co": "^4.6.0", | ||
"fs-extra": "^2.1.2" | ||
}, | ||
@@ -42,0 +48,0 @@ "dependencies": { |
@@ -7,3 +7,3 @@ # SmartPhoto | ||
- Use Accelerometer to move images | ||
- Scale images to the optimized size so to view each image clearly | ||
- Scale images to fill/fit on the screen so to view each image clearly | ||
@@ -10,0 +10,0 @@ ## Instration |
@@ -1,11 +0,31 @@ | ||
#! /usr/bin/env node | ||
var fs = require("fs"); | ||
var jsesc = require("jsesc"); | ||
var process_path = process.cwd(); | ||
var path = require('path'); | ||
var text = fs.readFileSync(path.resolve(process_path, "./src/index.js"), 'utf8'); | ||
text = text.replace(/import (.*?) from '((.*?)\.(html|css))'/g,function(a,b,c){ | ||
var template = jsesc(fs.readFileSync(path.resolve(process_path,"./src/",c), 'utf8')); | ||
return "var "+ b +" = \'"+template+"\'"; | ||
}); | ||
fs.writeFileSync(path.resolve(process_path,"./lib/prebuild.js"),text, 'utf8'); | ||
"use strict" | ||
const cmd = require('node-cmd'); | ||
const co = require('co'); | ||
const fs = require('fs-extra'); | ||
const pkg = require('../package.json'); | ||
const SystemPromise = (cmd_string) => { | ||
return new Promise((resolve, reject) => { | ||
cmd.get( | ||
cmd_string, | ||
(data, err, stderr) => { | ||
if ( err ) { | ||
console.log(err) | ||
} | ||
if ( stderr ) { | ||
console.log(stderr) | ||
} | ||
resolve(data) | ||
} | ||
) | ||
}) | ||
} | ||
co(function *() { | ||
try { | ||
yield SystemPromise(`git push origin v${pkg.version}`); | ||
yield SystemPromise(`npm publish`); | ||
} catch ( err ) { | ||
console.log(err) | ||
} | ||
}); |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
7372002
13040
19