As it is now for ` -x ` option for `-a` case : `-x firefox` = `-x firefox\*` = `-x \*firefox\*` = `-x /firefox\*` - it uses value to pattern *firefox* Question is - how should I exclude `firefox\*` pattern ? for `portname portname ...` case: `/` should be followed by name to exclude and works like `-x /firefox\*` to exclude any port beginning with `firefox\*` . Why do I need it? I don't want to compile huge ports like firefox, llvm, etc. and they are updated via `pkg upgrade`. Now in case of `-a` option I can't control it properly - for `-x llvm` it excludes needed to be excluded llvm70, llvm80 ... and needed to be included py36*llvm* either. Portmaster is 3.19_18 . Please, point me to ways, whether I fail. Thank you for development.
I have made for me a "exclude.txt" : -x firefox -x webkit\* -x rust\* -x gcc\* -x llvm\* -x virtuallbox-ose\* -x palemoon -x thunderbird -x vis -x abiword -a -d -y And call it from an update-script with: /usr/local/sbin/portmaster `cat /home/ngorx/exclude.txt|grep -v '#'` I think you can include a line with py36*llvm* (without -x). (the # is if I want to comment something out). I am not really clear if this is what you want.
correct /usr/local/sbin/portmaster `cat /home/ngorx/exclude.txt|grep -v '#'``
For py*llvm*: the wildcard does not work, you have insert separate lines py36-llvmcpy py36-llvmlite (I think you mean this two ports).
-x firefox matches firefox-0.0 and firefoxdehanaisomething-0.0. So I think -x firefox- is better than -x firefox . But, -x gimp- matches gimp-2.x and gimp-app-2.x. So I think -x gimp-\[0-9\] is better than -x gimp- . We can also use "pkg lock firefox" to avoid updating. However, the following prompt will appear. ===>>> firefox-x.x has an +IGNOREME file ===>>> Update anyway? y/n [n] I don't want portmaster to handle pkg-lock, so please remove this prompt from portmaster :)
I used -x without much concern. But my comment #4 is tremendously wrong :) -x is applied function globstrip. globstrip strips last * and last \. -x is used in function check_exclude. check_exclude is using case ... esac for pattern match. -x pattern is used as *pattern*. So, -x firefox is used as *firefox*. -x firefox-\[0-9\] may also match kankeinai-firefox-0.0 . mmm difficult.
(In reply to Tatsuki Makino from comment #4) Does `-y` option remove this prompt from portmaster ?
No!
Created attachment 202629 [details] patch for portmaster (In reply to w.schwarzenfeld from comment #1) I think this patch is necessary to make exclude.txt file like comment #1 work better. (In reply to mikhail.rokhin from comment #6) It seems that the places where -y and -n can be used are decided. -e, -s, --clean-distfiles, --clean-packages, --check-depends and --check-port-dbdir can be used.
Had no problems with the textfile.
If attachment 202629 [details] doesn't be used, more detailed llvm* patterns are needed to avoid other *llvm* like py36-llvmlite. For example, -x llvm[0-9][0-9]-[0-9] , -x llvm6[0-9]-6. or etc...
I'm not sure what to do with this PR. The patch that has been attached to this PR implements changed semantics for the "-x" option, and this might be considered a break of POLA. Therefore I do not plan to change the current behavior unless there is strong consensus (outside the list of participants of this PR) about the correct semantics.