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

nikelborm / fetch-github-folder / 14737640294

29 Apr 2025 05:33PM UTC coverage: 84.576% (+0.2%) from 84.334%
14737640294

push

github

nikelborm
fucking finally normal .ts extensions

74 of 80 branches covered (92.5%)

Branch coverage included in aggregate %.

22 of 26 new or added lines in 10 files covered. (84.62%)

7 existing lines in 2 files now uncovered.

584 of 698 relevant lines covered (83.67%)

3.89 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 } 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 {
×
12
  destinationPathCLIOptionBackedByEnv,
13
  downloadEntityFromRepo,
14
  gitRefCLIOptionBackedByEnv,
15
  OctokitLayer,
16
  pathToEntityInRepoCLIOptionBackedByEnv,
17
  repoNameCLIOptionBackedByEnv,
18
  repoOwnerCLIOptionBackedByEnv,
19
} from './src/index.ts';
20

21
// Those values updated automatically. If you edit names of constants or
22
// move them to a different file, update ./scripts/build.sh
23
const PACKAGE_VERSION = '0.1.22';
×
24
// TODO: read from ./package.json
UNCOV
25
const PACKAGE_NAME = 'fetch-github-folder';
×
26

27
const appCommand = make(
×
28
  PACKAGE_NAME,
×
29
  {
×
30
    repo: {
×
31
      owner: repoOwnerCLIOptionBackedByEnv,
×
32
      name: repoNameCLIOptionBackedByEnv,
×
33
    },
×
34
    pathToEntityInRepo: pathToEntityInRepoCLIOptionBackedByEnv,
×
35
    localPathAtWhichEntityFromRepoWillBeAvailable:
×
36
      destinationPathCLIOptionBackedByEnv,
×
37
    gitRef: gitRefCLIOptionBackedByEnv,
×
38
  },
×
39
  downloadEntityFromRepo,
×
UNCOV
40
);
×
41

UNCOV
42
const cli = run(appCommand, {
×
43
  // those values will be filled automatically from package.json
44
  name: PACKAGE_NAME,
×
45
  version: PACKAGE_VERSION,
×
UNCOV
46
});
×
47

48
pipe(
×
49
  process.argv,
×
50
  cli,
×
51
  provide(NodeFileSystemLayer),
×
52
  provide(NodePathLayer),
×
53
  provide(NodeTerminalLayer),
×
54
  provide(CliConfig.layer({ showTypes: false })),
×
55
  provide(
×
UNCOV
56
    OctokitLayer({
×
57
      // auth: getEnvVarOrFail('GITHUB_ACCESS_TOKEN'),
58
    }),
×
59
  ),
×
60
  runMain,
×
UNCOV
61
);
×
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