How to check for new versions without running the update?

If there is one or more update available the command pihole -up shows

[i] Pi-hole Core:	update available
[i] FTL:		    update available
[i] Web Interface:	update available

...but it also starts an update.

Is there a way or command to get the above information without updating the installed components?

My intention is to redirect the three lines to /etc/motd

pihole -v

Not really :slight_smile:

Pi-hole version is v3.3-65-g295ac49 (Latest: v3.3)
AdminLTE version is v3.2.1-80-g517fa24f (Latest: v3.3)
FTL version is vDev-a26da52 (Latest: v3.0)

Now I still don't know if this are the current versions in GitHub (FTLDNS branch).

An additional parameter for pihole -up would be great. Something like "check for updates and exit".

OK, I see what you mean now. Nothing like is in place right now. I don't think it would be too difficult though. Just a matter of doing it.

@mibere I simply visit the web GUI to check for updates :wink:

Just an aside for decoding the version string: v3.3-65-g295ac49 means version 3.3 plus 65 commits to the code with a git identifying hash of 295ac49. (See attached, this is the FTLDNS branch, note the Latest commit that matches the hash.)

This is because we are based off of git for version control, but there's some discussion on changing that to another type of release. The (Latest: v3.3) is indicating the 'tag' of the git release. It's just cleaner to use tags, but in reality the v3.3 release is v3.3-0-g1e87850 (sometimes the -0- is missing, but that gets in to the internals of git and GitHub.)

It would be ok for me if there is a "Update available" hint in the web interface even if on a development branch (FTLDNS). I could work with

curl -s http://192.168.x.x/admin/ | grep -i "Update available"

pihole -up
...
Update Complete!

Current Pi-hole version is v3.3-75-g82d5afe
Current AdminLTE version is v3.3-58-g89090261
Current FTL version is vDev-1ca6b58
[10 April 2018]

Is there an issue that you need assistance with? I'm not sure what you are asking or reporting.

No issue. All services appear to be running fine on original Raspberry Pi Model B after update.

However, as per the the topic heading, I was not able to determine whether there was an update available by looking at the web interface as suggested by Nero355.

You're right! It would just be a matter of passing though an extra flag. e.g pihole -up --check and then wrapping this section of code with something like:

if [[ ! ${1} == "--check" ]];then
   if [[ "${FTL_update}" == true || "${core_update}" == true || "${web_update}" == true ]]; then
    ${PI_HOLE_FILES_DIR}/automated\ install/basic-install.sh --reconfigure --unattended || \
         echo -e "${basicError}" && exit 1
  fi
fi

Would be cool if you have some time to implement this :slight_smile:

In progress...

Thanks, works as expected.