Skip to content

Commit ed951d4

Browse files
authored
Merge pull request #520 from ocaml/fix-win-repo
Set the upstream git url as a secondary repository on Windows
2 parents 7265446 + 85070d7 commit ed951d4

File tree

6 files changed

+27
-19
lines changed

6 files changed

+27
-19
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ and this project adheres to
88

99
## [unreleased]
1010

11+
### Changed
12+
13+
- Set the upstream git url as a secondary repository on Windows.
14+
1115
## [2.0.3]
1216

1317
### Added

dist/index.js

Lines changed: 8 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/post/index.js

Lines changed: 7 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/setup-ocaml/cache.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ function composeCygwinCachePaths() {
116116
const cygwinRootSymlinkPath = path.posix.join("/cygdrive", "d", "cygwin");
117117
paths.push(cygwinRootSymlinkPath);
118118
const cygwinEncodedUri = encodeURIComponent(
119-
"http://cygwin.mirror.constant.com/"
119+
"https://cygwin.mirror.constant.com/"
120120
).toLowerCase();
121121
const cygwinPackageRoot = path.join(githubWorkspace, cygwinEncodedUri);
122122
paths.push(cygwinPackageRoot);

src/setup-ocaml/constants.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -65,11 +65,11 @@ const repositories_yaml: { [key: string]: string } = yaml.parse(
6565

6666
const platform = getPlatform();
6767

68-
const defaultRepository =
69-
platform !== Platform.Win32
70-
? "https://github.com/ocaml/opam-repository.git"
71-
: "https://github.com/fdopen/opam-repository-mingw.git#opam2";
72-
7368
export const OPAM_REPOSITORIES: [string, string][] = repositories_yaml
7469
? Object.entries(repositories_yaml).reverse()
75-
: [["default", defaultRepository]];
70+
: platform !== Platform.Win32
71+
? [["default", "https://github.com/ocaml/opam-repository.git"]]
72+
: [
73+
["upstream", "https://github.com/ocaml/opam-repository.git"],
74+
["default", "https://github.com/fdopen/opam-repository-mingw.git#opam2"],
75+
];

src/setup-ocaml/opam.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ async function setupCygwin() {
178178
} else {
179179
core.addPath(cachedPath);
180180
}
181-
const site = "http://cygwin.mirror.constant.com";
181+
const site = "https://cygwin.mirror.constant.com";
182182
const packages = [
183183
"curl",
184184
"diffutils",

0 commit comments

Comments
 (0)