[Python-ideas] PEP 428 - object-oriented filesystem paths
Richard Oudkerk
shibturn at gmail.com
Sat Oct 6 02:27:49 CEST 2012
More information about the Python-ideas mailing list
Sat Oct 6 02:27:49 CEST 2012
- Previous message: [Python-ideas] PEP 428 - object-oriented filesystem paths
- Next message: [Python-ideas] PEP 428 - object-oriented filesystem paths
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 06/10/2012 12:48am, Antoine Pitrou wrote:
>>>> p = PureNTPath('c:/orders/12345/abc67890.dbf')
>>>> >>>p.parent()[p.name.split('.')[0] + '.csv']
> PureNTPath('c:\\orders\\12345\\abc67890.csv')
>
> Any suggestion to ease this use case a bit?
Maybe p.basename could be shorthand for p.name.split('.')[0].
Richard
- Previous message: [Python-ideas] PEP 428 - object-oriented filesystem paths
- Next message: [Python-ideas] PEP 428 - object-oriented filesystem paths
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-ideas mailing list