Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Fixes the shell command for linux distribution detection #11

Merged
merged 1 commit into from over 2 years ago

2 participants

Pedram Nimreezi Yurii Rashkovskii
Pedram Nimreezi

No description provided.

Yurii Rashkovskii yrashk merged commit bd582e1 into from
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Showing 1 unique commit by 1 author.

Feb 03, 2012
Pedram Nimreezi DeadZen Fix error on non ubuntu linux distros 0c88fec
This page is out of date. Refresh to see the latest.

Showing 1 changed file with 1 addition and 1 deletion. Show diff stats Hide diff stats

  1. +1 1  apps/htoad/src/htoad_host.erl
2  apps/htoad/src/htoad_host.erl
@@ -15,7 +15,7 @@ init(Engine, #init{}) when not {rule, [{htoad_argument, {host, _}}]} ->
15 15 initialize(Engine, hostname()).
16 16
17 17 -define(LINUX_DISTRO_SHELL,
18   - "([ `cat /etc/lsb-release | grep DISTRIB_ID` = DISTRIB_ID=Ubuntu ] && printf Ubuntu) ||
  18 + "([ -f /etc/lsb-release ] && [ `cat /etc/lsb-release | grep DISTRIB_ID` = DISTRIB_ID=Ubuntu ] && printf Ubuntu) ||
19 19 ([ -f /etc/redhat-release ] && [ `cat /etc/redhat-release | grep RedHat | wc -l` = 1 ] && printf RedHat) ||
20 20 ([ -f /etc/redhat-release ] && [ `cat /etc/redhat-release | grep CentOS | wc -l` = 1 ] && printf CentOS)").
21 21

Tip: You can add notes to lines in a file. Hover to the left of a line to make a note

Something went wrong with that request. Please try again.