Page Menu
Home
Software Heritage
Search
Configure Global Search
Log In
Files
F9312611
dot_add_content
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
393 B
Subscribers
None
dot_add_content
View Options
#!/bin/bash
DOT_FILE
=
"
$1
"
DOT_EXTRA
=
"
$2
"
if
[
-z
"
$DOT_FILE
"
-o
-z
"
$DOT_EXTRA
"
]
;
then
echo
"Usage:
$0
DOT_FILE DOT_EXTRA"
exit
1
fi
schema_version
=
$(
grep
-i
-A
1
'^insert into dbversion'
swh-schema.sql
|
tail
-n
1
\
|
sed
-e
's/.*values(//i'
-e
's/,.*//'
)
head
-n
-1
"
$DOT_FILE
"
# all of $DOT_FILE but last line
sed
"s/@@VERSION@@/
$schema_version
/"
"
$DOT_EXTRA
"
echo
"}"
File Metadata
Details
Attached
Mime Type
text/x-shellscript
Expires
Thu, Jul 3, 11:00 AM (1 w, 3 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3282143
Attached To
rDCIDX Metadata indexer
Event Timeline
Log In to Comment