mirror of
https://github.com/mickael-kerjean/filestash
synced 2025-12-06 08:22:24 +01:00
chore (maintenance): remove useless files
This commit is contained in:
parent
aed8712fd7
commit
b9f2ee959d
6 changed files with 1 additions and 166 deletions
4
.babelrc
4
.babelrc
|
|
@ -1,4 +0,0 @@
|
|||
{
|
||||
"presets": ["react", "es2015", "stage-2"],
|
||||
"plugins": ["transform-decorators-legacy", "syntax-dynamic-import"]
|
||||
}
|
||||
|
|
@ -1,16 +0,0 @@
|
|||
# http://editorconfig.org
|
||||
root = true
|
||||
[*]
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
end_of_line = lf
|
||||
charset = utf-8
|
||||
trim_trailing_whitespace = true
|
||||
insert_final_newline = true
|
||||
|
||||
[*.go]
|
||||
indent_size = 4
|
||||
indent_style = tab
|
||||
|
||||
[Makefile]
|
||||
indent_style = tab
|
||||
4
Jenkinsfile
vendored
4
Jenkinsfile
vendored
|
|
@ -22,10 +22,6 @@ pipeline {
|
|||
stage("Build") {
|
||||
steps {
|
||||
script {
|
||||
docker.image("node:20").inside("--user=root") {
|
||||
sh "apt update -y && apt install -y brotli"
|
||||
sh "npm install"
|
||||
}
|
||||
docker.image("golang:1.24-bookworm").inside("--user=root") {
|
||||
sh "apt update -y && apt install -y libbrotli-dev brotli"
|
||||
sh "sed -i 's|plg_image_c|plg_image_golang|' server/plugin/index.go"
|
||||
|
|
|
|||
18
package.json
18
package.json
|
|
@ -1,18 +0,0 @@
|
|||
{
|
||||
"name": "filestash",
|
||||
"version": "0.0.0",
|
||||
"description": "An app to manage your files in the cloud",
|
||||
"repository": "https://github.com/mickael-kerjean/filestash",
|
||||
"scripts": {
|
||||
"test": "jest ./client/",
|
||||
"lint": "eslint ./client/"
|
||||
},
|
||||
"author": "",
|
||||
"license": "AGPL",
|
||||
"dependencies": {},
|
||||
"devDependencies": {
|
||||
"eslint": "^8.5.0",
|
||||
"eslint-config-google": "^0.14.0",
|
||||
"eslint-plugin-react": "^7.27.1"
|
||||
}
|
||||
}
|
||||
|
|
@ -45,6 +45,7 @@
|
|||
}
|
||||
},
|
||||
"eslintConfig": {
|
||||
"root": true,
|
||||
"env": {
|
||||
"browser": true,
|
||||
"es2021": true,
|
||||
|
|
|
|||
|
|
@ -1,124 +0,0 @@
|
|||
const webpack = require("webpack");
|
||||
const path = require("path");
|
||||
const HtmlWebpackPlugin = require("html-webpack-plugin");
|
||||
// const BundleAnalyzerPlugin = require("webpack-bundle-analyzer").BundleAnalyzerPlugin;
|
||||
const UglifyJSPlugin = require("uglifyjs-webpack-plugin");
|
||||
const CopyWebpackPlugin = require("copy-webpack-plugin");
|
||||
const CompressionPlugin = require("compression-webpack-plugin");
|
||||
|
||||
const config = {
|
||||
entry: {
|
||||
app: path.join(__dirname, "client", "index.js"),
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "server", "ctrl", "static", "www"),
|
||||
publicPath: "/",
|
||||
filename: "assets/js/[name]_[chunkhash].js",
|
||||
chunkFilename: "assets/js/chunk_[name]_[id]_[chunkhash].js",
|
||||
},
|
||||
module: {
|
||||
rules: [
|
||||
{
|
||||
test: path.join(__dirname, "client"),
|
||||
use: ["babel-loader"],
|
||||
exclude: /node_modules/,
|
||||
},
|
||||
{
|
||||
test: /\.html$/,
|
||||
use: "html-loader",
|
||||
},
|
||||
{
|
||||
test: /\.woff2$/,
|
||||
use: "woff-loader",
|
||||
},
|
||||
{
|
||||
test: /\.scss$/,
|
||||
use: [
|
||||
{ loader: "style-loader" },
|
||||
{ loader: "css-loader" },
|
||||
{ loader: "sass-loader" },
|
||||
],
|
||||
},
|
||||
{
|
||||
test: /\.css$/,
|
||||
use: [
|
||||
{ loader: "style-loader" },
|
||||
{ loader: "css-loader" },
|
||||
],
|
||||
},
|
||||
{
|
||||
test: /\.(pdf|jpg|png|gif|svg|ico|woff|woff2|eot|ttf)$/,
|
||||
loader: "url-loader",
|
||||
},
|
||||
{
|
||||
test: /[a-z]+\.worker\.js$/,
|
||||
loader: "worker-loader",
|
||||
options: { name: "assets/js/[name]_[hash].js" },
|
||||
},
|
||||
],
|
||||
},
|
||||
plugins: [
|
||||
new webpack.DefinePlugin({
|
||||
"process.env.NODE_ENV": JSON.stringify(process.env.NODE_ENV),
|
||||
}),
|
||||
new HtmlWebpackPlugin({
|
||||
template: path.join(__dirname, "client", "index.html"),
|
||||
inject: true,
|
||||
minify: {
|
||||
collapseWhitespace: true,
|
||||
removeComments: true,
|
||||
minifyJS: true,
|
||||
minifyCSS: true,
|
||||
},
|
||||
}),
|
||||
new CopyWebpackPlugin([
|
||||
{ from: "locales/*.json", to: "assets/" },
|
||||
{ from: "worker/*.js", to: "assets/" },
|
||||
{ from: "assets/logo/*" },
|
||||
{ from: "assets/img/*" },
|
||||
{ from: "assets/icons/*" },
|
||||
{ from: "assets/fonts/*" },
|
||||
], { context: path.join(__dirname, "client") }),
|
||||
new CopyWebpackPlugin([
|
||||
{ from: "node_modules/pdfjs-dist/build/*.js", to: "assets/vendor/" },
|
||||
{ from: "node_modules/pdfjs-dist/cmaps/*", to: "assets/vendor/" },
|
||||
]),
|
||||
// new BundleAnalyzerPlugin()
|
||||
],
|
||||
resolve: {
|
||||
fallback: {
|
||||
"path": require.resolve("path-browserify"),
|
||||
"crypto": require.resolve("crypto-browserify"),
|
||||
"buffer": require.resolve("buffer/"),
|
||||
"stream": require.resolve("stream-browserify"),
|
||||
"vm": require.resolve("vm-browserify"),
|
||||
},
|
||||
},
|
||||
mode: process.env.NODE_ENV || "production",
|
||||
};
|
||||
|
||||
|
||||
if (process.env.NODE_ENV === "production") {
|
||||
// config.plugins.push(new UglifyJSPlugin({
|
||||
// sourceMap: false,
|
||||
// extractComments: true,
|
||||
// }));
|
||||
config.plugins.push(new CompressionPlugin({
|
||||
asset: "[path].gz[query]",
|
||||
algorithm: "gzip",
|
||||
test: /\.js$|\.json$|\.html$|\.svg|\.ico$/,
|
||||
threshold: 0,
|
||||
minRatio: 0.8,
|
||||
}));
|
||||
config.plugins.push(new CompressionPlugin({
|
||||
asset: "[path].br[query]",
|
||||
algorithm: "brotliCompress",
|
||||
test: /\.js$|\.json$|\.html$|\.svg|\.ico$/,
|
||||
threshold: 0,
|
||||
minRatio: 0.8,
|
||||
}));
|
||||
} else {
|
||||
config.devtool = "inline-source-map";
|
||||
}
|
||||
|
||||
module.exports = config;
|
||||
Loading…
Reference in a new issue