Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
microservice-autodevopspipelines
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
李春生
microservice-autodevopspipelines
Commits
9e77ac38
Commit
9e77ac38
authored
Jan 09, 2019
by
据说甜蜜呢
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加eval
parent
65d9c9d3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
6 deletions
+7
-6
devops/PipeLines/Functions.sh
+7
-6
No files found.
devops/PipeLines/Functions.sh
View file @
9e77ac38
...
...
@@ -6,7 +6,7 @@ function GetServiceName()
{
declare
servicePrefix
=
${
1
}
declare
serviceName
=
$(
ls
./src/services/
${
servicePrefix
}
|head
-n
1|xargs
-d
'/'
echo
)
$2
=
"
${
serviceName
}
"
eval
$2
=
"
${
serviceName
}
"
}
function
GetAppName
()
...
...
@@ -24,7 +24,7 @@ function GetCiCdSettings()
function
GetMajor
()
{
declare
major
=(
$(
grep
-oP
'(?<=VersionMajor>)[^<]+'
"devops/version.props"
)
)
$1
=
${
major
}
eval
$1
=
${
major
}
}
function
GetVersion
()
...
...
@@ -33,19 +33,19 @@ function GetVersion()
declare
minor
=(
$(
grep
-oP
'(?<=VersionMinor>)[^<]+'
"devops/version.props"
)
)
declare
patch
=(
$(
grep
-oP
'(?<=VersionPatch>)[^<]+'
"devops/version.props"
)
)
declare
version
=
${
major
}
.
${
minor
}
.
${
patch
}
$1
=
${
version
}
eval
$1
=
${
version
}
}
function
GetImageRegistrySettings
()
{
declare
host
=(
$(
grep
-oP
'(?<=ImageRegistryHost>)[^<]+'
"devops/deploy.props"
)
)
declare
username
=(
$(
grep
-oP
'(?<=ImageUserName>)[^<]+'
"devops/deploy.props"
)
)
$1
=
${
host
}
$2
=
${
username
}
eval
$1
=
${
host
}
eval
$2
=
${
username
}
}
function
GetAccessTokenOf
()
{
declare
token
=(
$(
grep
-oP
"(?<=
${
Environment
}
AccessToken>)[^<]+"
"devops/deploy.props"
)
)
$1
=
"
${
token
}
"
eval
$1
=
"
${
token
}
"
}
\ No newline at end of file
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