How to blacklist a package from being re-installed by ZYpp?


Sorry for posting this question in this forum, but I couldn’t find a forum that was better suited to it. My question is simply how can I blacklist a package from being installed by ZYpp when I run zypper dup? I suspect a package group I’ve installed contains the package git-gui, I’ve uninstalled it (as I do not need it) with zypper rm, but whenever I run zypper dup I get:

Repository 'NVIDIA' is up to date.                                                                                                                                                                                               
Repository 'Visual Studio Code' is up to date.                                                                                                                                                                                   
Repository 'Brenton Horne's OBS repository (openSUSE_Tumbleweed)' is up to date.                                                                                                                                                 
Repository 'openSUSE:Tumbleweed' is up to date.                                                                                                                                                                                  
Repository 'home:badshah400:Scilab6' is up to date.                                                                                                                                                                              
Repository 'science' is up to date.                                                                                                                                                                                              
Repository 'openSUSE-20180107-0' is up to date.                                                                                                                                                                                  
Repository 'packman' is up to date.                                                                                                                                                                                              
Repository 'openSUSE-Tumbleweed-Non-Oss' is up to date.                                                                                                                                                                          
Repository 'openSUSE-Tumbleweed-Source' is up to date.                                                                                                                                                                           
Repository 'openSUSE-Tumbleweed-Update' is up to date.                                                                                                                                                                           
All repositories have been refreshed.
Warning: You are about to do a distribution upgrade with all enabled repositories. Make sure these repositories are compatible before you continue. See 'man zypper' for more information about this command.
Loading repository data...
Reading installed packages...
Computing distribution upgrade...

Problem: problem with installed package 0ad-0.0.22-2.1.x86_64
 Solution 1: deinstallation of 0ad-0.0.22-2.1.x86_64
 Solution 2: keep obsolete 0ad-0.0.22-2.1.x86_64

Choose from above solutions by number or cancel [1/2/c] (c): 2
Resolving dependencies...
Computing distribution upgrade...

The following item is locked and will not be changed by any action:

The following NEW package is going to be installed:

1 new package to install.
Overall download size: 307.6 KiB. Already cached: 0 B. After the operation, additional 1.2 MiB will be used.
Continue? [y/n/...? shows all options] (y): n

the 0ad stuff is because presently the 0 A.D. package is broken on Tumbleweed (due to boost 1.66) and all unofficial OBS repositories containing 0ad seem to have the same problem, so I took the official src rpm and recompiled it locally. Oddly enough the build went fine and I installed the RPM I had built. As it is not provided by any repos ZYpp is upset by its presence. Back to the git-gui issue, is there a way to stop this attempt to install git-gui?

Thanks for your time,

Just add a lock to git-gui. When the package is not installed:
YaST > Softwaare Management > Search Phrase “git-gui”
Action | Lock

 # zypper al git-gui

Thanks for the hint on “zypper addlock”, I used it to lock tracker (see Trackers choking 3 (!) threads and Strange (high) HDD activity) as I could disable and deinstall it but after every “zypper dup” it was back.

My local rpmbuild-dir is stored as a Repo :

10 | Sauerland-rpmbuild              | Sauerland-rpmbuild                | Ja        | ( p) Ja         | Ja             |   32      | plaindir | dir:///home/Username/rpmbuild/RPMS

So all build rpms are automatically in my Software list for Yast/zypper…

You can add it via Yast----Software----Software-Repositories.

In yast software management right-click ‘git-gui’ and choose ‘taboo - never instal’.