OSDN Git Service

docs: fix filter-branch example for quoted paths
[git-core/git.git] / git-instaweb.sh
index 341930c..6a65f25 100755 (executable)
@@ -320,7 +320,7 @@ EOF
        else
                # plain-old CGI
                resolve_full_httpd
-               list_mods=$(echo "$full_httpd" | sed "s/-f$/-l/")
+               list_mods=$(echo "$full_httpd" | sed 's/-f$/-l/')
                $list_mods | sane_grep 'mod_cgi\.c' >/dev/null 2>&1 || \
                if test -f "$module_path/mod_cgi.so"
                then
@@ -394,8 +394,15 @@ gitweb_css () {
 EOFGITWEB
 }
 
+gitweb_js () {
+       cat > "$1" <<\EOFGITWEB
+@@GITWEB_JS@@
+EOFGITWEB
+}
+
 gitweb_cgi "$GIT_DIR/gitweb/gitweb.cgi"
 gitweb_css "$GIT_DIR/gitweb/gitweb.css"
+gitweb_js  "$GIT_DIR/gitweb/gitweb.js"
 
 case "$httpd" in
 *lighttpd*)