LinuxCommandLibrary

git-http-push

Update remote git repository via HTTP protocol

SYNOPSIS

git http-push [--all | --branches | --tags] [--dry-run] [--force] [--keep] [--thin] [--verbose] [ ...]
git http-push ...

PARAMETERS

--all
    Pushes all local branches to the remote repository. Functionally similar to --branches.

--branches
    Pushes all local branches to the remote repository.

--tags
    Pushes all local tags to the remote repository.

--dry-run
    Performs a 'dry run' operation, showing what would be pushed without actually performing the push. No data is actually transmitted or updated on the remote.

--force
    Forces the update, even if it results in a non-fast-forward merge. Use with caution as this can overwrite history on the remote.

--keep
    Keeps the pack file created on the server after the push operation. This is primarily for debugging or specific server-side scenarios and not typically used by end-users.

--thin
    Uses a 'thin pack' format during the push. This excludes objects that are already known to exist on the remote repository, potentially reducing the amount of data transferred.

--verbose
    Enables verbose output, providing more detailed information about the pushing process, including progress and network activity.


    The URL of the remote HTTP or HTTPS Git repository to which the local changes will be pushed. For example, http://example.com/repo.git.

...
    One or more local references (e.g., branch names, tag names, or SHA1 commit IDs) to push to the remote repository. For example, master or my-feature-branch.


    (Specific usage) In an older, less common usage of git-http-push, this parameter represents the current HEAD of the remote repository, typically refs/heads/master.

DESCRIPTION

git-http-push is a historical Git command primarily used for pushing local branches and their associated commits to a remote Git repository served over HTTP or HTTPS protocols. It was developed to provide an alternative to SSH or the native Git protocol, especially useful in environments where only HTTP/S outbound connections were permitted.

Important Note: This command is no longer actively maintained. Its functionality has been largely absorbed into the standard git push command. Users are strongly encouraged to use git push directly, even when dealing with HTTP/S remotes, as it provides a more robust, feature-rich, and actively maintained experience.

CAVEATS

The git-http-push command is considered obsolete and is no longer actively maintained. Its functionality has been fully integrated into git push, which is the recommended command for all remote operations, including those over HTTP/S.

Direct invocation of git-http-push may lead to unexpected behavior or be incompatible with newer Git versions or server configurations. Users should always use git push.

SERVER REQUIREMENTS

For git-http-push (and subsequently git push over HTTP/S) to function correctly, the remote HTTP/S server must be configured to support Git's 'smart HTTP' protocol. This typically involves the server running a Git HTTP backend application, such as git-http-backend, which processes Git protocol requests served via a web server like Apache or Nginx.

HISTORY

git-http-push was among the initial tools developed to facilitate Git repository interaction over standard web protocols (HTTP/S), offering an alternative when SSH or the dedicated Git protocol were not viable. It addressed early needs for pushing code in environments with restrictive firewall policies.

However, as Git matured, the core git push command evolved to natively support HTTP/S remotes. This made git-http-push largely redundant. Consequently, development ceased on git-http-push, and Git's official documentation now explicitly directs users to rely on the more comprehensive and actively developed git push command for all remote operations.

SEE ALSO

Copied to clipboard