code: func prePushCommand(cmd *cobra.Command, args []string) {
  	if len(args) == 0 {
  		Print("This should be run through Git's pre-push hook.  Run `git lfs update` to install it.")
  		os.Exit(1)
  	}
  
  	requireGitVersion()
  
  	// Remote is first arg
  	if err := cfg.SetValidPushRemote(args[0]); err != nil {
  		Exit("Invalid remote name %q: %s", args[0], err)
  	}
  
  	ctx := newUploadContext(prePushDryRun)
  	updates := prePushRefs(os.Stdin)
  	if err := uploadForRefUpdates(ctx, updates, false); err != nil {
  		ExitWithError(err)
  	}
  }
docs: // prePushCommand is run through Git's pre-push hook. The pre-push hook passes
  // two arguments on the command line:
  //
  //   1. Name of the remote to which the push is being done
  //   2. URL to which the push is being done
  //
  // The hook receives commit information on stdin in the form:
  //   <local ref> <local sha1> <remote ref> <remote sha1>
  //
  // In the typical case, prePushCommand will get a list of git objects being
  // pushed by using the following:
  //
  //    git rev-list --objects <local sha1> ^<remote sha1>
  //
  // If any of those git objects are associated with Git LFS objects, those
  // objects will be pushed to the Git LFS API.
  //
  // In the case of pushing a new branch, the list of git objects will be all of
  // the git objects in this branch.
  //
  // In the case of deleting a branch, no attempts to push Git LFS objects will be
  // made.