Skip to content

Commit

Permalink
Merge pull request #5 from skrenek/master
Browse files Browse the repository at this point in the history
wget Mac/Linux bug fix
  • Loading branch information
ryedin committed Apr 25, 2012
2 parents 14b2f73 + aa22007 commit ffddf73
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
2 changes: 1 addition & 1 deletion fvm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ fvm()
cd "$FVM_DIR/src" && \
mkdir -p "$VERSION" && \
cd "$VERSION" && \
wget "https://github.com/theVolary/feather/tarball/$VERSION" -O "$VERSION" && \
wget --no-check-certificate "https://github.com/theVolary/feather/tarball/$VERSION" -O "$VERSION" && \
tar -xzf "$VERSION" && \
cd the* && \
cp -r * ../../../${VERSION}/ && \
Expand Down
14 changes: 12 additions & 2 deletions tags.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,20 @@ var https = require("https"),

var installCheck = function(tag) {
if (path.existsSync(env.FVM_DIR + "/" + tag.trim())) {
return "\033[1;34m" + tag + "\033[0m";
var color = "1;34m";
if (isTagInUse(tag)) {
color = "1;32m";
}
return "\033[" + color + tag + "\033[0m";
}
return tag;
}
var isTagInUse = function(tag) {
if (env.FEATHER_HOME === env.FVM_DIR + "/" + tag.trim()) {
return true;
}
return false;
}
var getMaxTagNameLength = function(tags) {
var max = 0;
tags.forEach(function(item) {
Expand Down Expand Up @@ -44,7 +54,7 @@ https.get({
var maxPerLine = Math.floor(120 / width);
var line = "", i, j;

console.log("Available Tags (\033[1;34mBlue\033[0m are installed)");
console.log("Available Tags (\033[1;34mBlue\033[0m are installed, \033[1;32mGreen\033[0m is in use.)");

for (i = 0; i < tags.length; i+= maxPerLine) {
line = "";
Expand Down

0 comments on commit ffddf73

Please sign in to comment.