Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
script_deploy-artifact
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab 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
FOSS-AG
script_deploy-artifact
Commits
3af6d482
Commit
3af6d482
authored
May 16, 2018
by
Michael Gajda
Browse files
Options
Downloads
Patches
Plain Diff
Refactor and cleanup code
parent
40d474ed
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
deploy-artifact.sh
+10
-7
10 additions, 7 deletions
deploy-artifact.sh
with
10 additions
and
7 deletions
deploy-artifact.sh
+
10
−
7
View file @
3af6d482
...
...
@@ -3,18 +3,21 @@
# 2017 Michael Gajda <draget@speciesm.net>
# See LICENSE for license information
TURL
=
"https://cloud.foss-ag.de/public.php/webdav"
TUSER
=
"7bm6b2A8zTdHBE4"
USAGE
=
"
$0
<FILE/DIR>"
# check parameter
:
${
1
?Usage
:
$USAGE
}
#
Target
-dir will be repo
and
branch
DIR
=
$(
basename
${
TRAVIS_REPO_SLUG
}
)
-
${
TRAVIS_BRANCH
}
[
-z
$DIR
]
&&
echo
"
$0
: Could not find a Travis env"
&&
exit
1
# Creating a directory
with an
recursive
upload
is not possible with curl, use helper-script
#
Upload
-dir will be
<
repo
>-<
branch
>
UPLOAD
DIR
=
$(
basename
${
TRAVIS_REPO_SLUG
}
)
-
${
TRAVIS_BRANCH
}
[
-z
$
UPLOAD
DIR
]
&&
echo
"
$0
: Could not find a Travis env"
&&
exit
1
# Creating a directory recursive
ly
is not possible with curl, use helper-script
wget https://raw.githubusercontent.com/foss-ag/script_curl-dirup/v1.0.1/curl-dirup.sh
-O
curl-dirup.sh
&&
chmod
+x curl-dirup.sh
mkdir
-p
$
{
DIR
}
2>/dev/null
cp
-a
$@
$
{
DIR
}
mkdir
-p
$DIR
2>/dev/null
cp
-a
$@
$DIR
# Actual upload
./curl-dirup.sh
https://cloud.foss-ag.de/public.php/webdav 7bm6b2A8zTdHBE4
:
$PDFPW
$
{
DIR
}
./curl-dirup.sh
$TURL
$TUSER
:
$PDFPW
$DIR
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