• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

nikelborm / fetch-github-folder / 14743793886

30 Apr 2025 12:10AM UTC coverage: 85.344%. Remained the same
14743793886

push

github

nikelborm
quick save: Wed Apr 30 03:10:31 MSK 2025

74 of 80 branches covered (92.5%)

Branch coverage included in aggregate %.

584 of 691 relevant lines covered (84.52%)

3.92 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/fetch-github-folder.ts
1
#!/usr/bin/env node
2

3
import { CliConfig, Span } from '@effect/cli';
×
4
import { make, run } from '@effect/cli/Command';
×
5
import { layer as NodeFileSystemLayer } from '@effect/platform-node-shared/NodeFileSystem';
×
6
import { layer as NodePathLayer } from '@effect/platform-node-shared/NodePath';
×
7
import { runMain } from '@effect/platform-node-shared/NodeRuntime';
×
8
import { layer as NodeTerminalLayer } from '@effect/platform-node-shared/NodeTerminal';
×
9
import { provide } from 'effect/Effect';
×
10
import { pipe } from 'effect/Function';
×
11
import pkg from './package.json' with { type: 'json' };
×
12
import {
×
13
  destinationPathCLIOptionBackedByEnv,
14
  downloadEntityFromRepo,
15
  gitRefCLIOptionBackedByEnv,
16
  OctokitLayer,
17
  pathToEntityInRepoCLIOptionBackedByEnv,
18
  repoNameCLIOptionBackedByEnv,
19
  repoOwnerCLIOptionBackedByEnv,
20
} from './src/index.ts';
21

22
const appCommand = make(
×
23
  pkg.name,
×
24
  {
×
25
    repo: {
×
26
      owner: repoOwnerCLIOptionBackedByEnv,
×
27
      name: repoNameCLIOptionBackedByEnv,
×
28
    },
×
29
    pathToEntityInRepo: pathToEntityInRepoCLIOptionBackedByEnv,
×
30
    localPathAtWhichEntityFromRepoWillBeAvailable:
×
31
      destinationPathCLIOptionBackedByEnv,
×
32
    gitRef: gitRefCLIOptionBackedByEnv,
×
33
  },
×
34
  downloadEntityFromRepo,
×
35
);
×
36

37
const cli = run(appCommand, {
×
38
  name: pkg.name,
×
39
  version: pkg.version,
×
40
  summary: Span.text(pkg.description),
×
41
});
×
42

43
pipe(
×
44
  process.argv,
×
45
  cli,
×
46
  provide(NodeFileSystemLayer),
×
47
  provide(NodePathLayer),
×
48
  provide(NodeTerminalLayer),
×
49
  provide(CliConfig.layer({ showTypes: false })),
×
50
  provide(
×
51
    OctokitLayer({
×
52
      // auth: getEnvVarOrFail('GITHUB_ACCESS_TOKEN'),
53
    }),
×
54
  ),
×
55
  runMain,
×
56
);
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc