cloudflare/cloudflare-typescript

Public

mirrored fromhttps://github.com/cloudflare/cloudflare-typescriptAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
v6.0.0-beta.1

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

scripts/utils/git-swap.sh

13lines · modecode

1#!/usr/bin/env bash
2set -exuo pipefail
3# the package is published to NPM from ./dist
4# we want the final file structure for git installs to match the npm installs, so we
5
6# delete everything except ./dist and ./node_modules
7find . -maxdepth 1 -mindepth 1 ! -name 'dist' ! -name 'node_modules' -exec rm -rf '{}' +
8
9# move everything from ./dist to .
10mv dist/* .
11
12# delete the now-empty ./dist
13rmdir dist