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

Remove cURL in favor of using vcstool's ability to import URLs #683

Merged
merged 3 commits into from
Jun 21, 2021

Conversation

emersonknapp
Copy link
Contributor

Replaces #328 (thanks @rotu for starting it)

vcstool can take URLs, we can simplify logic by using this instead of expecting curl installed, or configuring it with advanced options

Signed-off-by: Emerson Knapp <eknapp@amazon.com>
@emersonknapp emersonknapp requested a review from a team as a code owner June 16, 2021 21:27
@emersonknapp emersonknapp requested review from MichaelOrlov and jaisontj and removed request for a team June 16, 2021 21:27
@emersonknapp emersonknapp mentioned this pull request Jun 16, 2021
@codecov
Copy link

codecov bot commented Jun 16, 2021

Codecov Report

Merging #683 (39c7964) into master (3882d9d) will not change coverage.
The diff coverage is 25.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #683   +/-   ##
=======================================
  Coverage   50.00%   50.00%           
=======================================
  Files           2        2           
  Lines         240      238    -2     
  Branches       52       52           
=======================================
- Hits          120      119    -1     
+ Misses        120      119    -1     
Impacted Files Coverage Δ
src/action-ros-ci.ts 43.06% <25.00%> (-0.07%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3882d9d...39c7964. Read the comment docs.

Signed-off-by: Emerson Knapp <eknapp@amazon.com>
@christophebedard
Copy link
Member

christophebedard commented Jun 17, 2021

Seems like vcs doesn't handle file:// URIs as well as curl does.

I think file://D: should have an additional slash (file:///D:) on Windows. Maybe we should use this instead of simply adding a file:// prefix: https://nodejs.org/api/url.html#url_url_pathtofileurl_path.

import * as url from "url";
// ...
		return url.pathToFileURL(path.resolve(vcsRepoFileUrl)).href;

Signed-off-by: Christophe Bedard <bedard.christophe@gmail.com>
@christophebedard
Copy link
Member

Maybe we should use this instead of simply adding a file:// prefix: nodejs.org/api/url.html#url_url_pathtofileurl_path.

I added it: 39c7964

@emersonknapp emersonknapp merged commit 7c7c917 into master Jun 21, 2021
@emersonknapp emersonknapp deleted the emersonknapp/remove-curl-vcs-input branch June 21, 2021 17:08
@emersonknapp
Copy link
Contributor Author

Thanks for fixing that!

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

Successfully merging this pull request may close these issues.

3 participants