Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
F
fakeImages
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
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
Show more breadcrumbs
vaclab
fakeImages
Commits
515fc4ea
Commit
515fc4ea
authored
7 years ago
by
Rolf Niepraschk
Browse files
Options
Downloads
Patches
Plain Diff
Parameter MAX_FILES
parent
197aab49
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
SRG-3/createImages
+27
-1
27 additions, 1 deletion
SRG-3/createImages
with
27 additions
and
1 deletion
SRG-3/createImages
+
27
−
1
View file @
515fc4ea
#!/bin/bash
#
# Rolf Niepraschk <Rolf.Niepraschk@ptb.de>, 2017-04-03
#
# neue Messgeräte-Bilder mit zufälliger Anzeige
#
# Parameter1 = Anzahl der erzeugten Bilddateien
# Parameter2 entfällt!
MAIN
=
"SRG-3"
# device name
IMAGE_DIR
=
./images
MAX_DIGITS
=
5
# do not edit!
MAX_FILES
=
10
# do not edit!
NUMBER_OF_DIGITS
=
$MAX_DIGITS
if
[
-n
"
$1
"
]
;
then
MAX_FILES
=
$1
if
[
-n
"
$2
"
]
;
then
NUMBER_OF_DIGITS
=
$2
fi
fi
if
((
$NUMBER_OF_DIGITS
>
$MAX_DIGITS
))
;
then
NUMBER_OF_DIGITS
=
$MAX_DIGITS
else
if
((
$NUMBER_OF_DIGITS
< 1
))
;
then
NUMBER_OF_DIGITS
=
1
fi
fi
rm
-rf
"
$IMAGE_DIR
"
mkdir
-p
"
$IMAGE_DIR
"
MAX_FILES=10
# https://stackoverflow.com/questions/296536/how-to-urlencode-data-for-curl-command
urlEncode
()
{
...
...
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