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

Incorrect ssh endpoints on Windows #1

Open
evil-shrike opened this issue Oct 30, 2013 · 3 comments
Open

Incorrect ssh endpoints on Windows #1

evil-shrike opened this issue Oct 30, 2013 · 3 comments

Comments

@evil-shrike
Copy link

I've setup a bowers-nest server on Windows box.
Then I run 'grunt register:mypackage' on the server.
It generates an endpoint for the package like:
ssh://127.0.0.1C:\Prog\bowers-nest/git_repositories/mypackage.git

It's incorrect url. Obviously bower on the client won't be able to install anything with such url.

Here's several issues. First it's IP-address. Why bowers-nest generates 127.0.0.1? It should be a public machine IP.
Second it's server path. Local path should be converted into url by removing ":" and replacing "" onto "/".

So correct url would be:
ssh://1.2.3.4/C/Prog/bowers-nest/git_repositories/mypackage.git

@presidenten
Copy link
Owner

Hi!

I have never tried it on Windows. Only Ubuntu, Redhat and Mac osx.

For the IP - Try this:
Delete and clone the repository again. After you have run "npm install" and "bower install" for the dependencies and "grunt" to run all the tests to see that everything works, please try to run the config grunt task like so:

grunt config:external-ip-adress:port-nr,

for example: grunt config:1.2.3.4:80

For the path, I suppose it needs a fix. But I dont have a Windows development machine. If you want to make this fix, I think you need to target the NodeJS variable "__dirname" on line 131 in Gruntfile.js.

Regards,

Johan

@presidenten
Copy link
Owner

Hello again!

Can you clone this new branch:
https://github.com/presidenten/bowers-nest/tree/FixWindowsPaths
and check if it works?

I would be happy if you can leave a note here if it does, so I can merge with the master branch.

Remember that you need to run:

grunt config:ip-adress:port

before you start registering packages.

@evil-shrike
Copy link
Author

Hi!
Actually I forked the repo and rewrote initialization in gruntfile as SSH doesn't work for me at all (SSH doesn't allow anonymous access so it's not much sense to publish bower component with ssh endpoint).
You can check my work in https://github.com/evil-shrike/bowers-nest if you will.

I also added ability to host dump git http server (and generated endpoint urls point at it) and some more grunt tasks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants