Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
contig_info
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
GIPhy
contig_info
Commits
0039402f
Commit
0039402f
authored
4 years ago
by
Alexis CRISCUOLO
Browse files
Options
Downloads
Patches
Plain Diff
2.01
parent
07e3a168
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
README.md
+1
-0
1 addition, 0 deletions
README.md
contig_info.sh
+10
-18
10 additions, 18 deletions
contig_info.sh
with
11 additions
and
18 deletions
README.md
+
1
−
0
View file @
0039402f
...
...
@@ -50,6 +50,7 @@ Run _contig_info_ without option to read the following documentation:
-r residue content statistics for each contig sequence instead of
global statistics
-t tab-delimited output
-h prints this help and exits
```
## Examples
...
...
This diff is collapsed.
Click to expand it.
contig_info.sh
+
10
−
18
View file @
0039402f
...
...
@@ -32,7 +32,11 @@
# = VERSIONS = #
# ============ #
# #
VERSION
=
2.0.210315ac
#
VERSION
=
2.01.210324ac
#
# + modified temp file creation using TMPDIR variable #
# + adding option -h #
# #
# VERSION=2.0.210315ac #
# + adding option -r #
# + adding trap when interrupting script #
# #
...
...
@@ -70,7 +74,7 @@
# ================ #
# #
# #
if
[
"
$1
"
=
"-
?
"
]
||
[
$#
-lt
1
]
if
[
"
$1
"
=
=
"-
h
"
]
||
[
$#
-lt
1
]
then
echo
-e
"
\n\0
33[1m contig_info v
$VERSION
$COPYRIGHT
\0
33[0m"
;
cat
<<
EOF
...
...
@@ -86,25 +90,14 @@ then
-r residue content statistics for each contig sequence instead of
global statistics
-t tab-delimited output
-h prints this help and exits
EOF
exit
;
[
"
$1
"
==
"-h"
]
&&
exit
0
||
exit
1
;
fi
# #
#############################################################################################################
#############################################################################################################
# #
# ================ #
# = CONSTANTS = #
# ================ #
# #
# = temp directory ======================================================================================= #
# #
TEMP_DIR
=
${
TMPDIR
:-
/tmp
}
;
# #
#############################################################################################################
#############################################################################################################
# #
# ================ #
...
...
@@ -112,11 +105,10 @@ fi
# ================ #
# #
# = randomfile() ========================================================================================= #
# re
turn
s a random file
name
within
/tmp/
#
#
c
re
ate
s a random file within
$TEMP_DIR and returns its name
#
# #
randomfile
()
{
rdmf
=
$TEMP_DIR
/
$RANDOM
;
while
[
-e
$rdmf
]
;
do
rdmf
=
$TEMP_DIR
/
$RANDOM
;
done
echo
$rdmf
;
echo
$(
mktemp
-t
-p
${
TMPDIR
:-
/tmp
}
)
;
}
# #
#############################################################################################################
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
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