Follow

マストドンだとこのくらい長い発言もできるんですよ(謎アピール)

```python
def _nvim_cd(args):
new_pwd = Path(args[0]).resolve() if len(args) > 0 else Path.cwd()
with neovim.attach("socket", path=$NVIM_LISTEN_ADDRESS) as nvim:
nvim.command("cd " + str(new_pwd))
print(nvim.eval("getcwd()"))

aliases["nvim_cd"] = _nvim_cd
```

· · Web · 0 · 2 · 4
Sign in to participate in the conversation
mstdn.jp

Mastodon日本鯖です. よろしくお願いいたします。 (Maintained by Sujitech, LLC)