FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
CodeIgniter4/.github/scripts/deploy-userguide at develop · codeigniter4/CodeIgniter4 · GitHub
Uh oh!
There was an error while loading.
Please reload this page
.
codeigniter4
/
CodeIgniter4
Public
Notifications
You must be signed in to change notification settings
Fork
2k
Star
6k
Code
Issues
26
Pull requests
7
Actions
Security and quality
17
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Security and quality
Insights
Expand file tree
Breadcrumbs
CodeIgniter4
/
.github
/
scripts
/
deploy-userguide
Copy path
More file actions
More file actions
Latest commit
History
History
History
executable file
·
61 lines (47 loc) · 1.31 KB
Breadcrumbs
CodeIgniter4
/
.github
/
scripts
/
deploy-userguide
Copy path
File metadata and controls
executable file
·
61 lines (47 loc) · 1.31 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
#!
/bin/bash
#
# Deploy codeigniter4/userguide
#
Setup variables
SOURCE=
$1
TARGET=
$2
RELEASE=
$3
#
Check if RELEASE is empty
if
[
-z
"
$RELEASE
"
]
;
then
echo
"
Error:
\$
RELEASE parameter is empty.
"
exit
1
fi
VERSION=
$(
echo
"
$RELEASE
"
|
cut -c 2-
)
#
Check if VERSION is empty
if
[
-z
"
$VERSION
"
]
;
then
echo
"
Error: Failed to extract
\$
VERSION from
\$
RELEASE parameter '
$RELEASE
'.
"
exit
1
fi
#
Check if VERSION matches the format X.Y.Z
if
!
[[
"
$VERSION
"
=~
^[0-9]+
\.
[0-9]+
\.
[0-9]+$ ]]
;
then
echo
"
Error: VERSION '
$VERSION
' does not match the expected format X.Y.Z.
"
exit
1
fi
echo
"
Preparing for version
$3
"
echo
"
Merging files from
$1
to
$2
"
#
Prepare the source
cd
$SOURCE
git checkout master
cd
user_guide_src
make html
make epub
#
Prepare the target
cd
$TARGET
git checkout master
rm -rf docs
#
Copy common files
cp -Rf
${SOURCE}
/LICENSE ./
#
Copy repo-specific files
cp -Rf
${SOURCE}
/admin/userguide/. ./
#
Copy files
cp -Rf
${SOURCE}
/user_guide_src/build/html ./docs
cp -Rf
${SOURCE}
/user_guide_src/build/epub/CodeIgniter.epub ./CodeIgniter
${VERSION}
.epub
#
Ensure underscore prefixed files are published
touch
${TARGET}
/docs/.nojekyll
#
Commit the changes
git add
.
git commit -m
"
Release
${RELEASE}
"
bash
${SOURCE}
/.github/scripts/secure-git-push https://github.com/codeigniter4/userguide.git HEAD:master
Back
|
FazBrowse Home
|
New Git URL