Announcement

Collapse
No announcement yet.

git push live server says Everything up-to-date

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • git push live server says Everything up-to-date

    I am learning git and trying to setup a workflow that will work for me.

    I am trying to setup an additional remote server for my live code.

    Code:
    origin: gitlab.com
    live: myserver
    I setup a `post-receive` hook in a bare repo on my server to deploy changes into the live folder (brand new, empty folder for testing)

    Issued `git push live master`

    First attempt:

    Code:
    stdin: is not a tty
    Counting objects: 454, done.
    Delta compression using up to 4 threads.
    Compressing objects: 100% (396/396), done.
    Writing objects: 100% (454/454), 2.52 MiB | 3.49 MiB/s, done.
    Total 454 (delta 45), reused 441 (delta 43)
    remote: Resolving deltas: 100% (45/45), done.
    hint: The 'hooks/post-receive' hook was ignored because it's not set as executable.
    hint: You can disable this warning with `git config advice.ignoredHook false`.
    To 122.201.115.185:/home/abseenet/git
    * [new branch] master -> master
    So I see that my post-receive hook was not executable so I fixed that and ran again. Now, everytime I run it, I get:

    Code:
    stdin: is not a tty
    Everything up-to-date
    Checking the repo on the server - the directory is completely empty... there is nothing there.

    How can I force an update or tell git to look again and that everything is not up to date?


  • #2
    Gee, this site active!

    Comment


    • #3
      I'll admit - we get more spam than active members. Work's been busy or I'd have already commented back.

      The 1st change you pushed up didn't get operated on by your post-receive hook because of the permissions - but the push succeeded (a post-hook can't prevent the operation if it fails).

      Your subsequent pushes are not pushing anything up because the 1st push succeeded and therefore not getting to the point of the post-receive hook execution.

      You need to make another change and push again. Given that some/all of the stuff you meant to get went up in your 1st push you may have to manually populate your live directory (depending on how you wrote the hook).

      Comment

      Working...
      X