Giter Club home page Giter Club logo

Comments (17)

moudey avatar moudey commented on August 16, 2024 1

str.replace function bug has been fixed

from shell.

moudey avatar moudey commented on August 16, 2024 1

path.wsl function has been added to help convert the path to wsl path

path.wsl(sel.path)

shell 1.8 beta

from shell.

moudey avatar moudey commented on August 16, 2024
item(
    title = "WSL Path"
    [email protected](path.separator(path.join("mnt", path.name(sel.root),str.sub(sel.path,3)), "/"))
)

from shell.

shafschwd avatar shafschwd commented on August 16, 2024

🤩 works like a charm thanks

from shell.

shafschwd avatar shafschwd commented on August 16, 2024

sorry i closed it before even testing it there are some problem i found

  1. there needs to be a slash before mnt like this \mnt otherwise this error shows up

image

  1. drive letter needs to be lower case

image

3.if there is a space between folder name it'll show a error if the file name is test tt you have to write it like cd test\ tt/

image

  1. related to 3 if there are multiple spaces between folder you have to write like this System\ Volume\ Information/ basically you need to end folders last word with / and before that \

image

thats all i found after a little bit of digging

from shell.

moudey avatar moudey commented on August 16, 2024

Use str.lower to convert chars to lowercase

str.lower(path.name(sel.root))

Use str.replace to replace space with "\ "

str.replace(sel.path, ' ', '\ ')

from shell.

shafschwd avatar shafschwd commented on August 16, 2024

Use str.lower to convert chars to lowercase

str.lower(path.name(sel.root))

Use str.replace to replace space with "\ "

str.replace(sel.path, ' ', '\ ')
item(title = "WSL Path"[email protected](path.separator(path.join("/mnt", str.lower(path.name(sel.root)),str.replace(sel.path, ' ', '\ ')), "/")))

everytime i try to copy path it crashes the explorer

from shell.

moudey avatar moudey commented on August 16, 2024

There is a bug in str.replace function that will be fixed in the next update

from shell.

shafschwd avatar shafschwd commented on August 16, 2024

aight ill be waiting for the update 😄

from shell.

shafschwd avatar shafschwd commented on August 16, 2024

path.wsl function has been added to help convert the path to wsl path

path.wsl(sel.path)

shell 1.8 beta

thank you so much

from shell.

shafschwd avatar shafschwd commented on August 16, 2024

im kinda confused how do i add it like this item(title='wsl' [email protected](sel.path)) ?

from shell.

shafschwd avatar shafschwd commented on August 16, 2024

or like i did before
item(title = "WSL Path"[email protected](path.separator(path.join("/mnt", str.lower(path.name(sel.root)),str.replace(sel.path, ' ', '\ ')), "/")))

from shell.

moudey avatar moudey commented on August 16, 2024
item(title='wsl' [email protected](sel.path))

from shell.

shafschwd avatar shafschwd commented on August 16, 2024

i dont know what im doing wrong here.

20220928_075726.mp4

and also do we have a discord server?

from shell.

moudey avatar moudey commented on August 16, 2024

Use sys.copy function to copy the path to the clipboard

item(title='wsl' [email protected](path.wsl(sel.path)))

from shell.

shafschwd avatar shafschwd commented on August 16, 2024

works perfectly thank you so much sorry for bothering you so much with this 😥.
although not related to this issue do you have a docs for the new stuff added on 1.8 and how to customise it.
i wanna decrease margin/padding from the sides of context menu container is there a doc u can point me to.

from shell.

machsix avatar machsix commented on August 16, 2024

Just an update, with the lastest version, this works

		item(mode="single" [email protected](sel.path) cmd=command.copy(path.wsl(sel.path)))

from shell.

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.