Showing
8 changed files
with
155 additions
and
5 deletions
static/.gitignore
0 → 100644
1 | +*.iml | ||
2 | +.idea/ | ||
3 | +.ipr | ||
4 | +.iws | ||
5 | +*~ | ||
6 | +~* | ||
7 | +*.diff | ||
8 | +*.patch | ||
9 | +*.bak | ||
10 | +.DS_Store | ||
11 | +Thumbs.db | ||
12 | +.project | ||
13 | +.*proj | ||
14 | +.svn/ | ||
15 | +*.swp | ||
16 | +*.swo | ||
17 | +*.pyc | ||
18 | +*.pyo | ||
19 | +.build | ||
20 | +node_modules | ||
21 | +_site | ||
22 | +sea-modules | ||
23 | +spm_modules | ||
24 | +.cache | ||
25 | +dist | ||
26 | +coverage | ||
27 | +css/ | ||
28 | +.sass-cache/ |
static/.spmignore
0 → 100644
static/config.rb
0 → 100644
1 | +require 'compass/import-once/activate' | ||
2 | +# Require any additional compass plugins here. | ||
3 | + | ||
4 | +# Set this to the root of your project when deployed: | ||
5 | +http_path = "/" | ||
6 | +css_dir = "css" | ||
7 | +sass_dir = "sass" | ||
8 | +images_dir = "img" | ||
9 | +javascripts_dir = "js" | ||
10 | +fonts_dir = "font" | ||
11 | + | ||
12 | +# You can select your preferred output style here (can be overridden via the command line): | ||
13 | +# output_style = :expanded or :nested or :compact or :compressed | ||
14 | +output_style = :expanded | ||
15 | +# To enable relative paths to assets via compass helper functions. Uncomment: | ||
16 | +relative_assets = true | ||
17 | + | ||
18 | +# To disable debugging comments that display the original location of your selectors. Uncomment: | ||
19 | +line_comments = false | ||
20 | + | ||
21 | + | ||
22 | +# If you prefer the indented syntax, you might want to regenerate this | ||
23 | +# project again passing --syntax sass, or you can uncomment this: | ||
24 | +# preferred_syntax = :sass | ||
25 | +# and then run: | ||
26 | +# sass-convert -R --from scss --to sass sass scss && rm -rf sass && mv scss sass | ||
27 | +Encoding.default_external = "utf-8" |
static/gulpfile.js
0 → 100644
1 | +/** | ||
2 | + * GULP-FILE | ||
3 | + * author: xuqi(qi.xu@yoho.cn) | ||
4 | + * date: 2015/9/30 | ||
5 | + */ | ||
6 | + | ||
7 | +var gulp = require('gulp'), | ||
8 | + compass = require('gulp-compass'), | ||
9 | + cp = require('child_process'); | ||
10 | + | ||
11 | +gulp.task('default', ['compass', 'compass-watch', 'spm-doc']); | ||
12 | + | ||
13 | +// compass | ||
14 | +gulp.task('compass', function() { | ||
15 | + gulp.src('sass/**/*.scss') | ||
16 | + .pipe( | ||
17 | + compass({ | ||
18 | + config_file: 'config.rb', | ||
19 | + css: 'css', | ||
20 | + sass: 'sass' | ||
21 | + }) | ||
22 | + ).on('error', function(error) { | ||
23 | + console.log(error); | ||
24 | + this.emit('end'); | ||
25 | + }); | ||
26 | +}); | ||
27 | + | ||
28 | +// compass watch | ||
29 | +gulp.task('compass-watch', function() { | ||
30 | + gulp.watch('sass/**/*.scss', ['compass']); | ||
31 | +}); | ||
32 | + | ||
33 | +// start spm server | ||
34 | +gulp.task('spm-doc', function() { | ||
35 | + var sd = cp.exec('spm doc'); | ||
36 | + | ||
37 | + // sd.stdout.on('data', function(data) { | ||
38 | + // console.log(data); | ||
39 | + // }); | ||
40 | + | ||
41 | + sd.stderr.on('data', function(data) { | ||
42 | + console.log(data); | ||
43 | + }); | ||
44 | + | ||
45 | + sd.on('exit', function(code) { | ||
46 | + console.log('process spm doc exit with code ' + code); | ||
47 | + }); | ||
48 | +}); |
static/index.js
0 → 100644
static/package.json
0 → 100644
1 | +{ | ||
2 | + "name": "yohobuy", | ||
3 | + "version": "0.0.1", | ||
4 | + "description": "yohobuy statics", | ||
5 | + "keywords": [], | ||
6 | + "homepage": "", | ||
7 | + "author": "xuqi <xuqi9010@gmail.com>", | ||
8 | + "repository": { | ||
9 | + "type": "git", | ||
10 | + "url": "" | ||
11 | + }, | ||
12 | + "bugs": { | ||
13 | + "url": "" | ||
14 | + }, | ||
15 | + "licenses": "MIT", | ||
16 | + "spm": { | ||
17 | + "main": "index.js", | ||
18 | + "dependencies": { | ||
19 | + }, | ||
20 | + "devDependencies": { | ||
21 | + "expect.js": "0.3.1" | ||
22 | + } | ||
23 | + }, | ||
24 | + "devDependencies": { | ||
25 | + "spm": "3", | ||
26 | + "gulp": "^3.9.0", | ||
27 | + "gulp-compass": "^2.1.0" | ||
28 | + }, | ||
29 | + "scripts": { | ||
30 | + "test": "spm test", | ||
31 | + "build": "spm build" | ||
32 | + } | ||
33 | +} |
static/sass/index.scss
0 → 100644
-
Please register or login to post a comment