Python Forum
only print the last folder ?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
only print the last folder ?
#2
What do you mean with wildcard?

and why

print(os.path.basename(os.path.normpath(src_1)))

That's enough

print(os.path.basename(src_1))
Gribouillis likes this post
Reply


Messages In This Thread
only print the last folder ? - by User3000 - May-21-2022, 09:01 PM
RE: only print the last folder ? - by Axel_Erfurt - May-21-2022, 09:16 PM
RE: only print the last folder ? - by User3000 - May-21-2022, 09:29 PM
RE: only print the last folder ? - by Gribouillis - May-21-2022, 09:38 PM
RE: only print the last folder ? - by Skaperen - May-21-2022, 10:54 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Compare folder A and subfolder B and display files that are in folder A but not in su Melcu54 3 646 Jan-05-2024, 05:16 PM
Last Post: Pedroski55
  Compare filename with folder name and copy matching files into a particular folder shantanu97 2 4,600 Dec-18-2021, 09:32 PM
Last Post: Larz60+
  Move file from one folder to another folder with timestamp added end of file shantanu97 0 2,531 Mar-22-2021, 10:59 AM
Last Post: shantanu97
  Python Cut/Copy paste file from folder to another folder rdDrp 4 5,186 Aug-19-2020, 12:40 PM
Last Post: rdDrp
  Delete directories in folder is not working after folder is updated asheru93 2 2,704 Feb-13-2019, 12:37 PM
Last Post: asheru93
  copy content of folder to existing folder shlomi27 0 2,677 Aug-11-2018, 01:44 PM
Last Post: shlomi27

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020