Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
M
mastofe
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
Pleroma
mastofe
Commits
89c0030d
There was a problem fetching the pipeline summary.
Verified
Commit
89c0030d
authored
7 years ago
by
Morgan Bazalgette
Browse files
Options
Downloads
Patches
Plain Diff
remove gzip
parent
733ef77e
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Pipeline
#
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
build.sh
+7
-0
7 additions, 0 deletions
build.sh
config/webpack/production.js
+2
-19
2 additions, 19 deletions
config/webpack/production.js
with
9 additions
and
19 deletions
build.sh
0 → 100755
+
7
−
0
View file @
89c0030d
#!/bin/sh
# Assuming pleroma sits in the upper directory under the dir "pleroma"
rm
-rf
public/packs public/assets
npm run build
cp
public/assets/sw.js ../pleroma/priv/static/sw.js
rm
-rf
../pleroma/priv/static/packs
cp
-r
public/packs ../pleroma/priv/static/packs
This diff is collapsed.
Click to expand it.
config/webpack/production.js
+
2
−
19
View file @
89c0030d
...
...
@@ -2,27 +2,16 @@
const
webpack
=
require
(
'
webpack
'
);
const
merge
=
require
(
'
webpack-merge
'
);
const
CompressionPlugin
=
require
(
'
compression-webpack-plugin
'
);
const
sharedConfig
=
require
(
'
./shared.js
'
);
const
BundleAnalyzerPlugin
=
require
(
'
webpack-bundle-analyzer
'
).
BundleAnalyzerPlugin
;
const
OfflinePlugin
=
require
(
'
offline-plugin
'
);
const
{
publicPath
}
=
require
(
'
./configuration.js
'
);
const
path
=
require
(
'
path
'
);
let
compressionAlgorithm
;
try
{
const
zopfli
=
require
(
'
node-zopfli
'
);
compressionAlgorithm
=
(
content
,
options
,
fn
)
=>
{
zopfli
.
gzip
(
content
,
options
,
fn
);
};
}
catch
(
error
)
{
compressionAlgorithm
=
'
gzip
'
;
}
module
.
exports
=
merge
(
sharedConfig
,
{
output
:
{
filename
:
'
[name]
-[chunkhash]
.js
'
,
chunkFilename
:
'
[name]
-[chunkhash]
.js
'
,
filename
:
'
[name].js
'
,
chunkFilename
:
'
[name].js
'
,
},
devtool
:
'
source-map
'
,
// separate sourcemap file, suitable for production
...
...
@@ -41,11 +30,6 @@ module.exports = merge(sharedConfig, {
comments
:
false
,
},
}),
new
CompressionPlugin
({
asset
:
'
[path].gz[query]
'
,
algorithm
:
compressionAlgorithm
,
test
:
/
\.(
js|css|html|json|ico|svg|eot|otf|ttf
)
$/
,
}),
new
BundleAnalyzerPlugin
({
// generates report.html and stats.json
analyzerMode
:
'
static
'
,
generateStatsFile
:
true
,
...
...
@@ -79,7 +63,6 @@ module.exports = merge(sharedConfig, {
'
/emoji/sheet.png
'
,
// used in emoji-mart
],
excludes
:
[
'
**/*.gz
'
,
'
**/*.map
'
,
'
stats.json
'
,
'
report.html
'
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment