Optimize OS/release/version detection for faster execution #70

Merged
benpro merged 86 commits from fast-debian-check into master 2019-04-05 11:01:57 +02:00
Owner

Related to #69

Related to #69
benpro added a new dependency 2019-03-21 10:36:35 +01:00
benpro reviewed 2019-03-21 10:46:41 +01:00
evocheck.sh Outdated
@ -128,0 +130,4 @@
if [ -e /etc/debian_version ]; then
DEBIAN_RELEASE=$(lsb_release -c -s)
DEBIAN_VERSION=$(cat /etc/debian_version |cut -d "." -f 1)
Contributor

Useless cat+pipe.

cut -d "." -f 1 < /etc/debian_version
Useless cat+pipe. ``` cut -d "." -f 1 < /etc/debian_version ```
evocheck.sh Outdated
@ -162,0 +186,4 @@
test "${DEBIAN_RELEASE}" = "stretch"
}
debian_release() {
printf "%s" "${DEBIAN_RELEASE}"
Contributor

printf is very useful when you want to replace many strings, but for one?

echo "${DEBIAN_RELEASE}"

is largely sufficient.

printf is very useful when you want to replace many strings, but for one? ``` echo "${DEBIAN_RELEASE}" ``` is largely sufficient.
Author
Owner

there is the question of the newline at the end, and I can't remember is it's a POSIX option.

there is the question of the newline at the end, and I can't remember is it's a POSIX option.
Contributor

You mean echo -n?
BTW this function is not used? I don't see any call.

You mean `echo -n`? BTW this function is not used? I don't see any call.
benpro added the
enhancement
label 2019-03-21 10:54:19 +01:00
benpro was assigned by jlecour 2019-03-21 12:54:41 +01:00
Author
Owner

I've rebased on master to resolve conflicts

I've rebased on master to resolve conflicts
benpro reviewed 2019-03-22 10:00:26 +01:00
jlecour reviewed 2019-03-23 02:23:45 +01:00
jlecour left a comment
Author
Owner

It would be cool to merge this PR, so we could focus on the others based on this one.

It would be cool to merge this PR, so we could focus on the others based on this one.
Author
Owner

@benpro You're right, the rebase was messed up. I've done it again. I hope it's good this time.

@benpro You're right, the rebase was messed up. I've done it again. I hope it's good this time.
benpro reviewed 2019-04-03 10:00:20 +02:00
Contributor

Beware it has moved at line 162.

Beware it has moved at line 162.
benpro approved these changes 2019-04-03 10:01:59 +02:00
Contributor

LGTM. @vlaborie Review welcome.

LGTM. @vlaborie Review welcome.
Author
Owner

@vlaborie tell me if you'd like to do a pair-review.

@vlaborie tell me if you'd like to do a pair-review.
Author
Owner

@benpro: Let's merge this, and then merge #75

@benpro: Let's merge this, and then merge #75
benpro closed this pull request 2019-04-05 11:01:57 +02:00
Sign in to join this conversation.
No description provided.