Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:illuusio:golang
gitea
gitea-fetch_source_and_node_modules.sh
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File gitea-fetch_source_and_node_modules.sh of Package gitea
#!/bin/sh function usage { echo "Usage: <script> <version>" echo "" echo "No more need till now. Only here for backup and if normal source file would change." echo "" exit 1; } if [[ -z "$1" ]]; then usage exit 1; fi VERSION="$1" PFAD=`pwd` mkdir gitea-dl cd gitea-dl echo "========================" echo "Download gitea souce ..." echo "========================" wget https://github.com/go-gitea/gitea/archive/v$VERSION/gitea-$VERSION.tar.gz wget https://github.com/go-gitea/gitea/releases/download/v$VERSION/gitea-docs-$VERSION.tar.gz wget https://github.com/go-gitea/gitea/releases/download/v$VERSION/gitea-docs-$VERSION.tar.gz.asc tar -xvzf gitea-$VERSION.tar.gz cd gitea-$VERSION rm package-lock.json echo "Must patch!" echo "With newest eslint-module-utils >= 2.7.0 gitea will not build." patch < ../../gitea-nodejs_package.json.patch # Install node_modules from package.json echo "==============================" echo "Install node_modules gitea ..." echo "==============================" npm install --no-save # Install node_modules for fomatic-ui echo "==========================================" echo "Install node_modules for fomatintic-ui ..." echo "==========================================" npm uninstall less npm install less@^3.13.1 merge-stream better-console del extend inquirer map-stream mkdirp normalize-path \ replace-ext require-dot-file wrench-sui yamljs \ gulp gulp-concat-filenames gulp-debug gulp-git gulp-clone gulp-concat gulp-concat-css \ gulp-copy gulp-dedupe gulp-flatten gulp-header \ gulp-if gulp-json-editor gulp-less gulp-notify gulp-plumber gulp-print gulp-rename \ gulp-replace gulp-rtlcss gulp-uglify gulp-autoprefixer gulp-chmod gulp-clean-css isobject # only download fomatic-ui and put under node_modules echo "=============================" echo "Download only fomantic-ui ..." echo "=============================" mkdir fomantic-build cd fomantic-build npm pack fomantic-ui tar -xvzf fomantic-ui-2.8.8.tgz cd .. cp -r fomantic-build/package node_modules/fomantic-ui # remove local home echo "=====================" echo "Remove local path ..." echo "=====================" find node_modules -type f -exec sed -i -e 's|'$PFAD'/gitea-dl/gitea-'$VERSION'||g' {} \; # pack node_modules echo "===========================" echo "Pack gitea-node_modules ..." echo "===========================" tar -czf ../gitea-node_modules-$VERSION.tar.gz node_modules cd .. # Copy echo "===========================" echo "Copy tars from /tmp to $PFAD ..." echo "===========================" cp gitea-$VERSION.tar.gz $PFAD cp gitea-node_modules-$VERSION.tar.gz $PFAD cp gitea-docs-$VERSION.tar.gz $PFAD cp gitea-docs-$VERSION.tar.gz.asc $PFAD echo "===========" echo "CleanUp ..." echo "===========" cd $PFAD rm -rf gitea-dl #rm -rf /tmp/gitea-$VERSION #rm -f /tmp/gitea-$VERSION.tar.gz #rm -f /tmp/gitea-node_modules-$VERSION.tar.gz
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor