Ticket #26 (closed enhancement: duplicate)

Opened 4 years ago

Last modified 2 months ago

percent-in could be improved and is buggy

Reported by: pterjan@… Owned by: misc@…
Priority: minor Milestone:
Component: rpmlint Version: trunk
Keywords: patch Cc:

Description (last modified by scop) (diff)

According to the code, the warning occurs when % appears in the scriptlet and %% does not. I th So, ink this is intended to trigger only unreplaced macros if they were intended.

So, the wanted behaviour would be :

  • %foo in the spec, %foo in the script -> warning
  • %%foo in the spec, %foo in the script -> OK

But the %% is looked for in the script so it will never appear and this part of the test is useless. Anyway it would not be optimal as %foo %%bar would not trigger the warning as the tests are separate.

Current behaviour is :

  • %foo in the spec, %foo in the script -> warning
  • %%foo in the spec, %foo in the script -> warning

Attachments

improve-percent-postcheck.diff Download (1.2 KB) - added by anonymous 3 years ago.

Change History

Changed 4 years ago by anonymous

  • summary changed from percent-in could be improved and is buggy to percent-in is buggy

Changed 4 years ago by scop

  • description modified (diff)

(Edited summary so it displays more understandably in Wiki)

Changed 3 years ago by misc

  • cc painting removed
  • component changed from website to rpmlint
  • summary changed from game to percent-in could be improved and is buggy
  • priority changed from trivial to minor
  • version changed from 0.77 to trunk
  • keywords game removed
  • type changed from task to enhancement

Changed 3 years ago by anonymous

I'm using the following patch with some success.

Changed 3 years ago by anonymous

Changed 2 years ago by misc

  • keywords patch added

Changed 2 months ago by scop

  • status changed from new to closed
  • resolution set to duplicate

A slightly different implementation of this has been in already for a while, see e.g. #132 and some earlier commits.

Add/Change #26 (percent-in could be improved and is buggy)

Author


E-mail address and user name can be saved in the Preferences.


Change Properties
<Author field>
Action
as closed
Next status will be 'reopened'
 
Note: See TracTickets for help on using tickets.