My tiny changes

This commit is contained in:
Thomas Boerger 2016-12-08 16:41:10 +01:00
parent 2a1c23d3a7
commit 731cc07aa4
No known key found for this signature in database
GPG Key ID: 5A388F55283960B6
6 changed files with 64 additions and 51 deletions

View File

@ -3,22 +3,24 @@ workspace:
pipeline: pipeline:
build: build:
image: node image: library/node:latest
commands: commands:
- make install - npm install -q
- make build - npm run clean
- make release - npm run build
- npm run release
release: release:
image: plugins/s3 image: plugins/s3
path_style: true path_style: true
source: master.tar.gz strip_prefix: dist/
target: /theme/ source: dist/master.tar.gz
target: /theme
when: when:
event: [ push ] event: [ push ]
branch: [ master ] branch: [ master ]
downstream: trigger:
image: plugins/downstream image: plugins/downstream
server: https://drone.gitea.io server: https://drone.gitea.io
repositories: repositories:
@ -27,8 +29,8 @@ pipeline:
- go-gitea/docs - go-gitea/docs
- go-gitea/redirects - go-gitea/redirects
when: when:
event: push event: [ push ]
branch: master branch: [ master ]
gitter: gitter:
image: plugins/gitter image: plugins/gitter

View File

@ -1 +1 @@
eyJhbGciOiJIUzI1NiJ9.d29ya3NwYWNlOgogIHBhdGg6IHNyYwoKcGlwZWxpbmU6CiAgYnVpbGQ6CiAgICBpbWFnZTogbm9kZQogICAgY29tbWFuZHM6CiAgICAgIC0gbWFrZSBpbnN0YWxsCiAgICAgIC0gbWFrZSBidWlsZAogICAgICAtIG1ha2UgcmVsZWFzZQoKICByZWxlYXNlOgogICAgaW1hZ2U6IHBsdWdpbnMvczMKICAgIHBhdGhfc3R5bGU6IHRydWUKICAgIHNvdXJjZTogbWFzdGVyLnRhci5negogICAgdGFyZ2V0OiAvdGhlbWUvCiAgICB3aGVuOgogICAgICBldmVudDogWyBwdXNoIF0KICAgICAgYnJhbmNoOiBbIG1hc3RlciBdCgogIGRvd25zdHJlYW06CiAgICBpbWFnZTogcGx1Z2lucy9kb3duc3RyZWFtCiAgICBzZXJ2ZXI6IGh0dHBzOi8vZHJvbmUuZ2l0ZWEuaW8KICAgIHJlcG9zaXRvcmllczoKICAg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NoOiBbIG1hc3RlciBdCgogIGdpdHRlcjoKICAgIGltYWdlOiBwbHVnaW5zL2dpdHRlcgo.N2Jze2NItEHFkItBvnoEO6Iw15Ar3kWd2QyJj5wByHo

2
.gitignore vendored
View File

@ -1,3 +1,3 @@
/master.tar.gz
/node_modules/ /node_modules/
/dist/
/static/styles/ /static/styles/

View File

@ -1,30 +0,0 @@
STYLES := static/styles
.PHONY: all
all: build
.PHONY: clean
clean:
rm -rf $(STYLES) master.tar.gz
.PHONY: install
install:
npm install -q
npm install -q -g gulp-cli
.PHONY: build
build:
gulp
.PHONY: release
release:
tar -cvzf master.tar.gz \
archetypes/ \
i18n/ \
layouts/ \
static/ \
DCO \
LICENSE \
MAINTAINERS \
README.md \
theme.toml

View File

@ -1,8 +1,30 @@
var gulp = require('gulp'); var gulp = require('gulp');
var sass = require('gulp-sass'); var sass = require('gulp-sass');
var sourcemaps = require('gulp-sourcemaps'); var sourcemaps = require('gulp-sourcemaps');
var tar = require('gulp-tar');
var gzip = require('gulp-gzip');
var clean = require('gulp-clean');
gulp.task('default', ['sass']); var sources = [
'archetypes',
'i18n',
'layouts',
'static',
'DCO',
'LICENSE',
'README.md',
'theme.toml'
];
gulp.task('default', ['build']);
gulp.task('build', ['sass']);
gulp.task('release', function () {
return gulp.src(sources)
.pipe(tar('master.tar'))
.pipe(gzip())
.pipe(gulp.dest('dist'))
});
gulp.task('sass', function () { gulp.task('sass', function () {
return gulp.src('./src/main.scss') return gulp.src('./src/main.scss')
@ -12,6 +34,11 @@ gulp.task('sass', function () {
.pipe(gulp.dest('./static/styles')); .pipe(gulp.dest('./static/styles'));
}); });
gulp.task('watch', function () { gulp.task('clean', function () {
gulp.watch('./src/*.scss', ['sass']); return gulp.src(['dist', 'static/styles'])
.pipe(clean());
});
gulp.task('watch', function () {
return gulp.watch('./src/*.scss', ['sass']);
}); });

View File

@ -1,22 +1,36 @@
{ {
"name": "gitea-theme", "name": "gitea-theme",
"description": "This is a Hugo theme that gets used within all of our websites like our blog, documentation and also the redirects.", "version": "0.0.0",
"description": "A Hugo theme that gets used within all of our websites.",
"homepage": "https://github.com/go-gitea/theme#readme",
"license": "Apache-2.0",
"author": {
"name": "The Gitea Authors",
"email": "team@gitea.io"
},
"repository": { "repository": {
"type": "git", "type": "git",
"url": "git+https://github.com/go-gitea/theme.git" "url": "https://github.com/go-gitea/theme.git"
}, },
"author": "The Gitea Authors",
"license": "Apache-2.0",
"bugs": { "bugs": {
"url": "https://github.com/go-gitea/theme/issues" "url": "https://github.com/go-gitea/theme/issues",
"email": "team@gitea.io"
},
"scripts": {
"clean": "gulp clean",
"build": "gulp build",
"release": "gulp release",
"watch": "gulp watch"
}, },
"homepage": "https://github.com/go-gitea/theme#readme",
"dependencies": { "dependencies": {
"bootstrap": "^4.0.0-alpha.5" "bootstrap": "^4.0.0-alpha.5"
}, },
"devDependencies": { "devDependencies": {
"gulp": "^3.9.1", "gulp": "^3.9.1",
"gulp-clean": "^0.3.2",
"gulp-gzip": "^1.4.0",
"gulp-sass": "^2.3.2", "gulp-sass": "^2.3.2",
"gulp-sourcemaps": "^1.9.1" "gulp-sourcemaps": "^1.9.1",
"gulp-tar": "^1.9.0"
} }
} }