Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Plan 9 acme #25

Closed
fhs opened this issue Nov 5, 2019 · 12 comments
Closed

Add support for Plan 9 acme #25

fhs opened this issue Nov 5, 2019 · 12 comments
Labels
enhancement New feature or request

Comments

@fhs
Copy link
Collaborator

fhs commented Nov 5, 2019

acme-lsp should be made to work on Plan 9 (or 9front). Currently, it doesn't work because of 9fans.net/go packages and because we use unix domain sockets.

@fhs fhs added the enhancement New feature or request label Nov 5, 2019
@fhs fhs self-assigned this Nov 5, 2019
@fhs fhs removed their assignment Dec 28, 2019
@ghost
Copy link

ghost commented Mar 7, 2020

Hey Fazlul, I'd like to help making this work in 9front. Did you have any ideas already on how to tackle this? Is the only problem the way mountAcme works?

@fhs
Copy link
Collaborator Author

fhs commented Mar 8, 2020

There is a PR open for 9fans.net/go plan9 support: 9fans/go#28
We may need to maintain a fork with changes from that PR or we somehow need to create a wrapper around it.

mountAcme is not the only issue. Anything that uses unix domain socket (including the plumber client and acme-lsp's LSP proxy server/client) needs to be changed to support plan9.

PRs are welcome.

@ghost
Copy link

ghost commented Mar 10, 2020

In #34 I think I addressed your points about integration with acme and plumber (while for the moment for the proxy I'm just reverting to tcp via CLI flags). Made some progress debugging the PR; right now my issue is that /mnt/acme/log does not exist in 9front! I did not see this coming. The log file was introduced in p9p in https://codereview.appspot.com/89560044/.

@otremblay
Copy link

I tried applying the patch by hand on 9front in order to add the log support to acme; it worked fine, as far as I could tell. Backporting that patch should do the trick. I have no idea how to do that, but if you need some help on that I wouldn't mind figuring it out.

@ghost
Copy link

ghost commented May 11, 2020

Hey @otremblay I was waiting for some feedback from Fazlul either here or on the PR before taking the next step. I'm working on something else right now and I'll stick with *BSD + p9p for the time being. FWIW, I'd also considered applying the patch to 9front's acme, but didn't get around to it.

@fhs
Copy link
Collaborator Author

fhs commented May 11, 2020

Another option is to use Edwood on Plan 9, which has log support. The issue again comes down to 9fans.net/go (Edwood dependency) not supporting Plan 9. I think I'll make a temporary fork of 9fans.net/go to make this all work.

@fhs
Copy link
Collaborator Author

fhs commented May 12, 2020

I've created an importable 9fans.net/go fork with plan9 support:

go get github.com/fhs/[email protected]

This should give us a good starting point for acme-lsp plan9 support.

If you want to try out Edwood for log support, you'll need to change all the import paths first:

{ echo X ,x!"9fans.net/go/! c!"github.com/fhs/9fans-go/!; echo X w; echo q } | 
sam -d `{du -a | grep '\.go$' | awk '{print $2}'}

There is a small issue with accessing the plan9 plumber. Edwood tries to mount the plumb service when it's usually already mounted at /mnt/plumb on plan9. You can comment it out to get it started.

@fhs
Copy link
Collaborator Author

fhs commented Jun 5, 2020

Update:
I've posted a patch to add the log file in acme in the 9front mailing list (see /n/lists/9front/1591327702.00).

I've also created a plan9 branch, which has some of the commands already working.

@fhs
Copy link
Collaborator Author

fhs commented Jun 9, 2020

The acme log patch has been merged into 9front and I fixed the remaining issues. acme-lsp on master supports plan9 now.

Work remaining:

  • It would be nice to use /srv for the proxy server. You need to use tcp right now.
  • Need to set up CI using sr.ht

@perpen
Copy link

perpen commented Jun 15, 2020

Indeed it works, thanks Fazlul.

@ghost
Copy link

ghost commented Jul 6, 2020

I've created an importable 9fans.net/go fork with plan9 support:

go get github.com/fhs/[email protected]

Thank you for uploading this fork. It's generally extremely useful. I hope your PR in the original package will be merged someday!

@fhs
Copy link
Collaborator Author

fhs commented Oct 21, 2020

Thanks for verifying it works.

I wasn't able to set up CI for plan9 -- trying to run tests in qemu. It would've been easier if kvm was supported.

@fhs fhs closed this as completed Oct 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants