git/list[1] front-page[2] threads[3] people[4] search[5] about
 

How can I tell if a file has been updated upstream?

From
TTTimur Tabi <timur@freescale.com>
Date
Feb 5, 2010, 16:23 UTC
Message-ID
<ed82fe3e1002050823gec57827j184c9c4cff4f4a45@mail.gmail.com>

Is there a way for me to tell if a particular file in my repository has an update in the upstream repository? For example, the SHA of the HEAD is different in the remote repository than it is of the HEAD in the local repository.

The reason I ask is that I have a set of Python scripts that I distribute via git (other people in the company clone my repository). I want my script, every time it's run, to check if an update is available, and ask the user to do "git pull".

-- 
Timur Tabi
Linux kernel developer at Freescale
Next: Shawn O. Pearce
Message 1 of 7 in “How can I tell if a file has been updated upstream?”
  1. Timur TabiFeb 5, 2010
  2. Shawn O. PearceFeb 5, 2010
  3. Timur TabiFeb 5, 2010
  4. Nicolas PitreFeb 5, 2010
  5. Junio C HamanoFeb 5, 2010
  6. Timur TabiFeb 5, 2010
  7. Timur TabiFeb 26, 2010

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.