Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
Acme.Sh
Commits
1b3e1a7a
Commit
1b3e1a7a
authored
Jul 07, 2022
by
Bjarke Bruun
Browse files
Changed 'grep -E' to '_egrep_o' 'removed ()'
parent
0afabc60
Changes
1
Hide whitespace changes
Inline
Side-by-side
dnsapi/dns_dnsservices.sh
View file @
1b3e1a7a
...
...
@@ -213,7 +213,7 @@ deleteRecord() {
result
=
"
$(
_H1
=
"
$_H1
"
_H2
=
"
$_H2
"
_get
"
$DNSServices_API
/service/
$rootZoneServiceID
/dns/
$rootZoneDomainID
"
)
"
recordInfo
=
"
$(
echo
"
$result
"
|
tr
'}'
'\n'
|
grep
"
\"
name
\"
:
\"
${
fulldomain
}
"
|
grep
"
\"
content
\"
:
\"
"
|
grep
"
${
txtvalue
}
"
)
"
_debug2 deleteRecord
"recordInfo=
$recordInfo
"
recordID
=
"
$(
echo
"
$recordInfo
"
|
tr
','
'\n'
| _egrep_o
()
"
\"
id
\"
:
\"
[0-9]+
\"
"
|
cut
-d
'"'
-f4
)
"
recordID
=
"
$(
echo
"
$recordInfo
"
|
tr
','
'\n'
| _egrep_o
"
\"
id
\"
:
\"
[0-9]+
\"
"
|
cut
-d
'"'
-f4
)
"
if
[
-z
"
$recordID
"
]
;
then
_info
"Record
$fulldomain
TXT
$txtvalue
not found or already deleted"
...
...
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