Updating Emoncms Git error

Continuing the discussion from Emoncms v9.8.25:

I Tried this on a fairly fresh install on DietPi and I get this.

root@DietPi-Emoncms:/var/www/emoncms # git pull
remote: Counting objects: 239, done.
remote: Compressing objects: 100% (10/10), done.
remote: Total 239 (delta 128), reused 129 (delta 126), pack-reused 102
Receiving objects: 100% (239/239), 54.73 KiB | 0 bytes/s, done.
Resolving deltas: 100% (176/176), completed with 34 local objects.
From https://github.com/emoncms/emoncms
   b8a10f9..d1bce95  stable             -> origin/stable
 * [new branch]      device-integration -> origin/device-integration
   efe402a..f6b0220  device-support     -> origin/device-support
   69476c9..255a422  master             -> origin/master
 * [new tag]         9.8.25             -> 9.8.25
 * [new tag]         9.8.27             -> 9.8.27
Updating b8a10f9..d1bce95
error: Your local changes to the following files would be overwritten by merge:
        Lib/tablejs/custom-table-fields.js
        Modules/input/Views/input_api.php
        Modules/input/input_methods.php
        Modules/input/input_model.php
        Modules/input/locale/fr_FR/LC_MESSAGES/messages.mo
        Modules/input/locale/fr_FR/LC_MESSAGES/messages.po
        Modules/process/process_model.php
        Modules/process/process_processlist.php
        Modules/user/user_model.php
        Modules/user/user_schema.php
        index.php
        scripts/phpmqtt_input.php
Please commit your changes or stash them before you merge.
Aborting

Have I done something wrong?

Can anyone suggest what I should do?

(disclaimer I am not a git expert)

Are any of these files something you’ve modified for your own use?

    Lib/tablejs/custom-table-fields.js
    Modules/input/Views/input_api.php
    Modules/input/input_methods.php
    Modules/input/input_model.php
    Modules/input/locale/fr_FR/LC_MESSAGES/messages.mo
    Modules/input/locale/fr_FR/LC_MESSAGES/messages.po
    Modules/process/process_model.php
    Modules/process/process_processlist.php
    Modules/user/user_model.php
    Modules/user/user_schema.php
    index.php
    scripts/phpmqtt_input.php

if those files are not something you’ve modified then they can be ignored and overwritten.

Look up git reset and git clean commands. (these are done from the same /var/www/emoncms directory). One of those should remove or ignored those files so the git pull will work.

I don’t think you did anything wrong. It is just one of those git issues that pop up once in awhile!

Hi Jon, no nothing I have changed. A very clean install this one!

that is a good thing. much easy to fix!

 

read thru this post:

Thanks. Looked up a couple of such items and settled on

git fetch --all
git reset --hard origin/stable

Seems to have done the trick with no adverse effects!

1 Like