fi
}
- # switches from an X:/ form to a /cygdrive/X/path form. this is only useful
- # for the cygwin environment currently.
- function dos_to_unix_path() {
- # we always remove dos slashes in favor of forward slashes.
-#old: echo "$1" | sed -e 's/\\/\//g' | sed -e 's/\([a-zA-Z]\):\/\(.*\)/\/\1\/\2/'
- echo "$1" | sed -e 's/\\/\//g' | sed -e 's/\([a-zA-Z]\):\/\(.*\)/\/cygdrive\/\1\/\2/'
- }
+# # switches from an X:/ form to a /cygdrive/X/path form. this is only useful
+# # for the cygwin environment currently.
+# function dos_to_unix_path() {
+# # we always remove dos slashes in favor of forward slashes.
+##old: echo "$1" | sed -e 's/\\/\//g' | sed -e 's/\([a-zA-Z]\):\/\(.*\)/\/\1\/\2/'
+# echo "$1" | sed -e 's/\\/\//g' | sed -e 's/\([a-zA-Z]\):\/\(.*\)/\/cygdrive\/\1\/\2/'
+# }
# returns a successful value (0) if this system is debian or ubuntu.
function debian_like() {
# some preconditions we want to establish before loading anything...
# make sure that aliases can be used in non-interactive shells.
+ # this causes all aliases that are currently defined for this shell to
+ # be inherited by subshells that this shell starts. this is unusual,
+ # but is preferred for my workflow in feisty meow scripts; it saves me
+ # time re-adding aliases if i can count on them already being there.
+ # this is a problem if you *don't* want the aliases there though. we can
+ # solve that problem by running bash with the "-O expand_aliases" flags to
+ # stop the expansion for the next subshell.
shopt -s expand_aliases
# patch the user variable if we were launched by one of our cron jobs.
##############
-#hmmm: moved from functions.sh; does that hose everything up?
-
# defines a variable within the feisty meow environment and remembers that
# this is a new or modified definition. if the feisty meow codebase is
# unloaded, then so are all the variables that were defined.
return 0
}
+ # switches from an X:/ form to a /cygdrive/X/path form. this is only useful
+ # for the cygwin environment currently.
+ # defined here rather than in functions.sh since we need it when setting variables
+ # and cannot count on load order during a fresh startup in some circumstances.
+ function dos_to_unix_path() {
+ # we always remove dos slashes in favor of forward slashes.
+#old: echo "$1" | sed -e 's/\\/\//g' | sed -e 's/\([a-zA-Z]\):\/\(.*\)/\/\1\/\2/'
+ echo "$1" | sed -e 's/\\/\//g' | sed -e 's/\([a-zA-Z]\):\/\(.*\)/\/cygdrive\/\1\/\2/'
+ }
+
+
##############