Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
chromebrew
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
chromebrew
Commits
e39cf980
Commit
e39cf980
authored
Jul 02, 2017
by
lyxell
Committed by
GitHub
Jul 02, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #810 from jam7/refactor/crew-compress
Change crew to compress manual files at install time
parents
5a6ab67d
899d789a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
3 deletions
+24
-3
crew
crew
+24
-3
No files found.
crew
View file @
e39cf980
...
...
@@ -27,6 +27,9 @@ else
CREW_NPROC
=
ENV
[
"CREW_NPROC"
]
end
#
Set
CREW_NOT_COMPRESS
from
environment
variable
CREW_NOT_COMPRESS
=
ENV
[
"CREW_NOT_COMPRESS"
]
#
Set
CREW_NOT_STRIP
from
environment
variable
CREW_NOT_STRIP
=
ENV
[
"CREW_NOT_STRIP"
]
...
...
@@ -422,17 +425,35 @@ def build_and_preconfigure (target_dir)
end
end
def
compress_doc
(
dir
)
#
check
whether
crew
should
compress
return
if
CREW_NOT_COMPRESS
||
!File.exist?("#{CREW_PREFIX}/bin/compressdoc")
if
Dir
.
exist
?
dir
system
"find #{dir} -type f ! -perm -200 | xargs -r chmod u+w"
system
"compressdoc --gzip -9 #{dir}"
end
end
def
prepare_package
(
destdir
)
Dir
.
chdir
destdir
do
#
create
directory
list
#
compress
manual
files
compress_doc
"#{destdir}#{CREW_PREFIX}/man"
compress_doc
"#{destdir}#{CREW_PREFIX}/info"
compress_doc
"#{destdir}#{CREW_PREFIX}/share/man"
compress_doc
"#{destdir}#{CREW_PREFIX}/share/info"
#
create
directory
list
system
"find . -type f > ../filelist"
system
"find . -type l >> ../filelist"
system
"cut -c2- ../filelist > filelist"
#
create
file
list
#
create
file
list
system
"find . -type d > ../dlist"
system
"cut -c2- ../dlist > dlistcut"
system
"tail -n +2 dlistcut > dlist"
#
remove
temporary
files
#
remove
temporary
files
system
"rm dlistcut ../dlist ../filelist"
end
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment