Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ruanhaishen
Acme.Sh
Commits
59115949
Commit
59115949
authored
Dec 07, 2017
by
speedmann
Browse files
Fix egrep invocation
parent
9a1f7698
Changes
1
Hide whitespace changes
Inline
Side-by-side
dnsapi/dns_inwx.sh
View file @
59115949
...
...
@@ -78,7 +78,7 @@ dns_inwx_add() {
_info
"Adding record"
_inwx_add_record
"
$_domain
"
"
$_sub_domain
"
"
$txtvalue
"
else
_record_id
=
$(
printf
'%s'
"
$response
"
| _egrep_o
'.*(<member><name>record){1}(.*)([0-9]+){1}'
| _egrep_o
'<name>id<\/name><value><int>[0-9]+'
| egrep
-
o
'[0-9]+'
)
_record_id
=
$(
printf
'%s'
"
$response
"
| _egrep_o
'.*(<member><name>record){1}(.*)([0-9]+){1}'
| _egrep_o
'<name>id<\/name><value><int>[0-9]+'
|
_
egrep
_
o
'[0-9]+'
)
_info
"Updating record"
_inwx_update_record
"
$_record_id
"
"
$txtvalue
"
fi
...
...
@@ -155,7 +155,7 @@ dns_inwx_rm() {
if
!
printf
"%s"
"
$response
"
|
grep
"count"
>
/dev/null
;
then
_info
"Do not need to delete record"
else
_record_id
=
$(
printf
'%s'
"
$response
"
| _egrep_o
'.*(<member><name>record){1}(.*)([0-9]+){1}'
| _egrep_o
'<name>id<\/name><value><int>[0-9]+'
| egrep
-
o
'[0-9]+'
)
_record_id
=
$(
printf
'%s'
"
$response
"
| _egrep_o
'.*(<member><name>record){1}(.*)([0-9]+){1}'
| _egrep_o
'<name>id<\/name><value><int>[0-9]+'
|
_
egrep
_
o
'[0-9]+'
)
_info
"Deleting record"
_inwx_delete_record
"
$_record_id
"
fi
...
...
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