{
    "content": [
        {
            "type": "text",
            "text": "# git-instaweb (man)\n\n## NAME\n\ngit-instaweb - Instantly browse your working repository in gitweb\n\n## SYNOPSIS\n\ngit instaweb [--local] [--httpd=<httpd>] [--port=<port>]\n[--browser=<browser>]\ngit instaweb [--start] [--stop] [--restart]\n\n## DESCRIPTION\n\nA simple script to set up gitweb and a web server for browsing the local repository.\n\n## TLDR\n\n> Helper to launch a GitWeb server.\n\n- Launch a GitWeb server for the current Git repository:\n  `git instaweb --start`\n- Listen only on localhost:\n  `git instaweb --start {{-l|--local}}`\n- Listen on a specific port:\n  `git instaweb --start {{-p|--port}} {{1234}}`\n- Use a specified HTTP daemon:\n  `git instaweb --start {{-d|--httpd}} {{lighttpd|apache2|mongoose|plackup|webrick}}`\n- Also auto-launch a web browser:\n  `git instaweb --start {{-b|--browser}}`\n- Stop the currently running GitWeb server:\n  `git instaweb --stop`\n- Restart the currently running GitWeb server:\n  `git instaweb --restart`\n\n*Source: tldr-pages*\n\n## Sections\n\n- **NAME**\n- **SYNOPSIS**\n- **DESCRIPTION**\n- **OPTIONS** (5 subsections)\n- **CONFIGURATION**\n- **SEE ALSO**\n- **GIT**\n\nUse structuredContent.sections for detailed options, examples, and full documentation.\n"
        }
    ],
    "structuredContent": {
        "command": "git-instaweb",
        "section": "",
        "mode": "man",
        "summary": "git-instaweb - Instantly browse your working repository in gitweb",
        "synopsis": "git instaweb [--local] [--httpd=<httpd>] [--port=<port>]\n[--browser=<browser>]\ngit instaweb [--start] [--stop] [--restart]",
        "tldr_summary": "Helper to launch a GitWeb server.",
        "tldr_examples": [
            {
                "description": "Launch a GitWeb server for the current Git repository",
                "command": "git instaweb --start"
            },
            {
                "description": "Listen only on localhost",
                "command": "git instaweb --start {{-l|--local}}"
            },
            {
                "description": "Listen on a specific port",
                "command": "git instaweb --start {{-p|--port}} {{1234}}"
            },
            {
                "description": "Use a specified HTTP daemon",
                "command": "git instaweb --start {{-d|--httpd}} {{lighttpd|apache2|mongoose|plackup|webrick}}"
            },
            {
                "description": "Also auto-launch a web browser",
                "command": "git instaweb --start {{-b|--browser}}"
            },
            {
                "description": "Stop the currently running GitWeb server",
                "command": "git instaweb --stop"
            },
            {
                "description": "Restart the currently running GitWeb server",
                "command": "git instaweb --restart"
            }
        ],
        "tldr_source": "official",
        "flags": [
            {
                "flag": "-l",
                "long": "--local",
                "arg": null,
                "description": "Only bind the web server to the local IP (127.0.0.1)."
            },
            {
                "flag": "-d",
                "long": "--httpd",
                "arg": null,
                "description": "The HTTP daemon command-line that will be executed. Command-line options may be specified here, and the configuration file will be added at the end of the command-line. Currently apache2, lighttpd, mongoose, plackup, python and webrick are supported. (Default: lighttpd)"
            },
            {
                "flag": "-m",
                "long": "--module-path",
                "arg": null,
                "description": "The module path (only needed if httpd is Apache). (Default: /usr/lib/apache2/modules)"
            },
            {
                "flag": "-p",
                "long": "--port",
                "arg": null,
                "description": "The port number to bind the httpd to. (Default: 1234)"
            },
            {
                "flag": "-b",
                "long": "--browser",
                "arg": null,
                "description": "The web browser that should be used to view the gitweb page. This will be passed to the git web--browse helper script along with the URL of the gitweb instance. See git- web--browse(1) for more information about this. If the script fails, the URL will be printed to stdout. start, --start Start the httpd instance and exit. Regenerate configuration files as necessary for spawning a new instance. stop, --stop Stop the httpd instance and exit. This does not generate any of the configuration files for spawning a new instance, nor does it close the browser. restart, --restart Restart the httpd instance and exit. Regenerate configuration files as necessary for spawning a new instance."
            }
        ],
        "examples": [],
        "see_also": [
            {
                "name": "gitweb",
                "section": "1",
                "url": "https://www.chedong.com/phpMan.php/man/gitweb/1/json"
            }
        ],
        "section_outline": [
            {
                "name": "NAME",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "SYNOPSIS",
                "lines": 5,
                "subsections": []
            },
            {
                "name": "DESCRIPTION",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "OPTIONS",
                "lines": 1,
                "subsections": [
                    {
                        "name": "-l, --local",
                        "lines": 2,
                        "flag": "-l",
                        "long": "--local"
                    },
                    {
                        "name": "-d, --httpd",
                        "lines": 5,
                        "flag": "-d",
                        "long": "--httpd"
                    },
                    {
                        "name": "-m, --module-path",
                        "lines": 2,
                        "flag": "-m",
                        "long": "--module-path"
                    },
                    {
                        "name": "-p, --port",
                        "lines": 2,
                        "flag": "-p",
                        "long": "--port"
                    },
                    {
                        "name": "-b, --browser",
                        "lines": 17,
                        "flag": "-b",
                        "long": "--browser"
                    }
                ]
            },
            {
                "name": "CONFIGURATION",
                "lines": 13,
                "subsections": []
            },
            {
                "name": "SEE ALSO",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "GIT",
                "lines": 5,
                "subsections": []
            }
        ],
        "sections": {
            "NAME": {
                "content": "git-instaweb - Instantly browse your working repository in gitweb\n",
                "subsections": []
            },
            "SYNOPSIS": {
                "content": "git instaweb [--local] [--httpd=<httpd>] [--port=<port>]\n[--browser=<browser>]\ngit instaweb [--start] [--stop] [--restart]\n\n",
                "subsections": []
            },
            "DESCRIPTION": {
                "content": "A simple script to set up gitweb and a web server for browsing the local repository.\n",
                "subsections": []
            },
            "OPTIONS": {
                "content": "",
                "subsections": [
                    {
                        "name": "-l, --local",
                        "content": "Only bind the web server to the local IP (127.0.0.1).\n",
                        "flag": "-l",
                        "long": "--local"
                    },
                    {
                        "name": "-d, --httpd",
                        "content": "The HTTP daemon command-line that will be executed. Command-line options may be specified\nhere, and the configuration file will be added at the end of the command-line. Currently\napache2, lighttpd, mongoose, plackup, python and webrick are supported. (Default:\nlighttpd)\n",
                        "flag": "-d",
                        "long": "--httpd"
                    },
                    {
                        "name": "-m, --module-path",
                        "content": "The module path (only needed if httpd is Apache). (Default: /usr/lib/apache2/modules)\n",
                        "flag": "-m",
                        "long": "--module-path"
                    },
                    {
                        "name": "-p, --port",
                        "content": "The port number to bind the httpd to. (Default: 1234)\n",
                        "flag": "-p",
                        "long": "--port"
                    },
                    {
                        "name": "-b, --browser",
                        "content": "The web browser that should be used to view the gitweb page. This will be passed to the\ngit web--browse helper script along with the URL of the gitweb instance. See git-\nweb--browse(1) for more information about this. If the script fails, the URL will be\nprinted to stdout.\n\nstart, --start\nStart the httpd instance and exit. Regenerate configuration files as necessary for\nspawning a new instance.\n\nstop, --stop\nStop the httpd instance and exit. This does not generate any of the configuration files\nfor spawning a new instance, nor does it close the browser.\n\nrestart, --restart\nRestart the httpd instance and exit. Regenerate configuration files as necessary for\nspawning a new instance.\n",
                        "flag": "-b",
                        "long": "--browser"
                    }
                ]
            },
            "CONFIGURATION": {
                "content": "You may specify configuration in your .git/config\n\n[instaweb]\nlocal = true\nhttpd = apache2 -f\nport = 4321\nbrowser = konqueror\nmodulePath = /usr/lib/apache2/modules\n\n\nIf the configuration variable instaweb.browser is not set, web.browser will be used instead\nif it is defined. See git-web--browse(1) for more information about this.\n",
                "subsections": []
            },
            "SEE ALSO": {
                "content": "gitweb(1)\n",
                "subsections": []
            },
            "GIT": {
                "content": "Part of the git(1) suite\n\n\n\nGit 2.34.1                                   02/26/2026                              GIT-INSTAWEB(1)",
                "subsections": []
            }
        }
    }
}