Code Monkey home page Code Monkey logo

Comments (3)

newville avatar newville commented on August 17, 2024

@maphew make_shortcut could return the full paths. For now, you could do:

  scut = make_shortcut(scriptcmd, name="Script Name", icon=iconpath)
  targets  = [os.path.join(f, scut.target) for f in (scut.desktop, scut.start_menu)]

For programmatically deleting shortcuts, I suppose pyshortcuts could keep a file (say in $HOME/.config/pyshortcuts.created_links) that records where shortcuts are made so that it can also have a method to clean these out. Sort of like Windows "Add/Remove Programs".

I can definitely see how "Remove App" could be important. At least, it gives the user the choice to clean up unused (or flaky or conflicting) versions of Apps. I'm less sure about "Remove Shortcuts".

That is, I guess I view the shortcuts as handy placeholders for running apps that the user can alter or delete. I think a lot of people find them annoying and/or carefully manage what is on their desktop, start menu, taskbar, Dock, etc so the Apps they need most are easily found by them.
Still, I can see that it could be useful to be able to try to clean up what was installed. That almost seems like it would have to be part of pip/setuptools or conda or whatever package manager was used.

from pyshortcuts.

maphew avatar maphew commented on August 17, 2024

Thanks for the list comprehension alternate. Agreed that remove app is better than remove shortcut and that the proper place for all this is a package manager. They're not there yet! Thinking about it more. Remove shortcut fits my sense of symmetry but is probably not all that useful in the real world. People are going to conda or pip remove thing and only later "oh yeah, the shortctuts too", at which time it will be too late for this.

from pyshortcuts.

maphew avatar maphew commented on August 17, 2024

I'm closing this as not needed sufficiently enough to warrant the work (and maintenance). The stub is here if anyone wants to re-open and run with it.

from pyshortcuts.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.