Ticket #13263 (closed enhancement: fixed)
lint: check that port name matches port directory name
| Reported by: | ryandesign@… | Owned by: | macports-tickets@… |
|---|---|---|---|
| Priority: | Normal | Milestone: | MacPorts 1.7.0 |
| Component: | base | Version: | 1.6.0 |
| Keywords: | Cc: | afb@…, jmpp@… | |
| Port: |
Description
port lint should check whether the port name declared in the portfile matches the name of the directory the port resides in.
For example, the file devel/qtcsharp/Portfile says the port's name is qtsharp (missing the c). (Filed as #13262.) lint should catch this error.
Change History
comment:2 Changed 6 years ago by afb@…
Another example (from Ryan) is php5, it is listing categories in wrong order.
(says "lang php www" while it should be something like "www php lang" instead)
comment:3 Changed 6 years ago by afb@…
- Status changed from new to closed
- Resolution set to fixed
Fixed, r30996.
Made it an error for the time being, if portpkg building is added later it can be revised.
comment:5 Changed 5 years ago by ryandesign@…
- Status changed from closed to reopened
- Cc afb@…, jmpp@… added; ryandesign@… removed
- Resolution fixed deleted
r30996 did not implement the feature requested in this ticket. It checks that the port category matches the directory the port's in. That's good but not what this ticket requests. This ticket requests that the port name (defined with the name keyword in the portfile) is the same as the name of the directory the Portfile is in. See the original problem that triggered this request, as per the issue description above, and see another instance of the problem which was fixed in r33525 which it would be nice if port lint could have caught.


This one is more tricky, while it is generally true for the SVN ports tree, it's also possible to build ports from a developer snapshot or older version or maybe even from a portpkg in the future.
But it could be a warning.