-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
330 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"name": "Ubuntu", | ||
"image": "mcr.microsoft.com/devcontainers/base:jammy", | ||
"workspaceFolder": "/workspace", | ||
"remoteEnv": { | ||
"PATH": "/root/.proto/shims:/root/.proto/bin:${containerEnv:PATH}" | ||
}, | ||
"customizations": { | ||
"jetbrains": { | ||
"backend": "IntelliJ" | ||
} | ||
}, | ||
"postCreateCommand": ".devcontainer/setup.sh" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env bash | ||
|
||
curl -fsSL https://moonrepo.dev/install/proto.sh | PROTO_HOME=/usr/local bash -s -- --yes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,175 @@ | ||
# Based on https://raw.githubusercontent.com/github/gitignore/main/Node.gitignore | ||
|
||
# Logs | ||
|
||
logs | ||
_.log | ||
npm-debug.log_ | ||
yarn-debug.log* | ||
yarn-error.log* | ||
lerna-debug.log* | ||
.pnpm-debug.log* | ||
|
||
# Caches | ||
|
||
.cache | ||
|
||
# Diagnostic reports (https://nodejs.org/api/report.html) | ||
|
||
report.[0-9]_.[0-9]_.[0-9]_.[0-9]_.json | ||
|
||
# Runtime data | ||
|
||
pids | ||
_.pid | ||
_.seed | ||
*.pid.lock | ||
|
||
# Directory for instrumented libs generated by jscoverage/JSCover | ||
|
||
lib-cov | ||
|
||
# Coverage directory used by tools like istanbul | ||
|
||
coverage | ||
*.lcov | ||
|
||
# nyc test coverage | ||
|
||
.nyc_output | ||
|
||
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files) | ||
|
||
.grunt | ||
|
||
# Bower dependency directory (https://bower.io/) | ||
|
||
bower_components | ||
|
||
# node-waf configuration | ||
|
||
.lock-wscript | ||
|
||
# Compiled binary addons (https://nodejs.org/api/addons.html) | ||
|
||
build/Release | ||
|
||
# Dependency directories | ||
|
||
node_modules/ | ||
jspm_packages/ | ||
|
||
# Snowpack dependency directory (https://snowpack.dev/) | ||
|
||
web_modules/ | ||
|
||
# TypeScript cache | ||
|
||
*.tsbuildinfo | ||
|
||
# Optional npm cache directory | ||
|
||
.npm | ||
|
||
# Optional eslint cache | ||
|
||
.eslintcache | ||
|
||
# Optional stylelint cache | ||
|
||
.stylelintcache | ||
|
||
# Microbundle cache | ||
|
||
.rpt2_cache/ | ||
.rts2_cache_cjs/ | ||
.rts2_cache_es/ | ||
.rts2_cache_umd/ | ||
|
||
# Optional REPL history | ||
|
||
.node_repl_history | ||
|
||
# Output of 'npm pack' | ||
|
||
*.tgz | ||
|
||
# Yarn Integrity file | ||
|
||
.yarn-integrity | ||
|
||
# dotenv environment variable files | ||
|
||
.env | ||
.env.development.local | ||
.env.test.local | ||
.env.production.local | ||
.env.local | ||
|
||
# parcel-bundler cache (https://parceljs.org/) | ||
|
||
.parcel-cache | ||
|
||
# Next.js build output | ||
|
||
.next | ||
out | ||
|
||
# Nuxt.js build / generate output | ||
|
||
.nuxt | ||
dist | ||
|
||
# Gatsby files | ||
|
||
# Comment in the public line in if your project uses Gatsby and not Next.js | ||
|
||
# https://nextjs.org/blog/next-9-1#public-directory-support | ||
|
||
# public | ||
|
||
# vuepress build output | ||
|
||
.vuepress/dist | ||
|
||
# vuepress v2.x temp and cache directory | ||
|
||
.temp | ||
|
||
# Docusaurus cache and generated files | ||
|
||
.docusaurus | ||
|
||
# Serverless directories | ||
|
||
.serverless/ | ||
|
||
# FuseBox cache | ||
|
||
.fusebox/ | ||
|
||
# DynamoDB Local files | ||
|
||
.dynamodb/ | ||
|
||
# TernJS port file | ||
|
||
.tern-port | ||
|
||
# Stores VSCode versions used for testing VSCode extensions | ||
|
||
.vscode-test | ||
|
||
# yarn v2 | ||
|
||
.yarn/cache | ||
.yarn/unplugged | ||
.yarn/build-state.yml | ||
.yarn/install-state.gz | ||
.pnp.* | ||
|
||
# IntelliJ based IDEs | ||
.idea | ||
|
||
# Finder (MacOS) folder config | ||
.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1 @@ | ||
black = "24.3.0" | ||
k3d = "5.6.0" | ||
k9s = "0.32.4" | ||
moon = "1.23.4" | ||
tilt = "0.33.12" | ||
|
||
[plugins] | ||
black = "source:https://raw.githubusercontent.com/appthrust/proto-toml-plugins/main/black/plugin.toml" | ||
k3d = "source:https://raw.githubusercontent.com/appthrust/proto-toml-plugins/main/k3d/plugin.toml" | ||
k9s = "source:https://raw.githubusercontent.com/appthrust/proto-toml-plugins/main/k9s/plugin.toml" | ||
moon = "source:https://raw.githubusercontent.com/moonrepo/moon/master/proto-plugin.toml" | ||
tilt = "source:https://raw.githubusercontent.com/appthrust/proto-toml-plugins/main/tilt/plugin.toml" | ||
bun = "1.1.15" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,80 @@ | ||
{ | ||
"$schema": "https://biomejs.dev/schemas/1.8.0/schema.json", | ||
"files": { | ||
// relative path from the workspace root | ||
"ignore": [".moon"] | ||
}, | ||
"vcs": { | ||
"enabled": true, | ||
"clientKind": "git", | ||
"defaultBranch": "main", | ||
"useIgnoreFile": true | ||
}, | ||
"organizeImports": { | ||
"enabled": true | ||
}, | ||
"formatter": { | ||
"enabled": true, | ||
"lineWidth": 120 | ||
}, | ||
"linter": { | ||
"enabled": true, | ||
"rules": { | ||
"recommended": true, | ||
"style": { | ||
"useFilenamingConvention": { | ||
"level": "warn", | ||
"options": { | ||
"strictCase": false, | ||
"requireAscii": true, | ||
"filenameCases": ["kebab-case"] | ||
} | ||
}, | ||
"noDefaultExport": "warn", | ||
"noNegationElse": "warn", | ||
"useBlockStatements": "warn", | ||
"useCollapsedElseIf": "warn", | ||
"useConsistentArrayType": { | ||
"level": "warn", | ||
"options": { | ||
"syntax": "shorthand" | ||
} | ||
}, | ||
"useForOf": "warn", | ||
"useFragmentSyntax": "warn", | ||
"useShorthandArrayType": "warn", | ||
"useShorthandAssign": "warn" | ||
}, | ||
"complexity": { | ||
"useLiteralKeys": "off" | ||
}, | ||
"correctness": { | ||
"useArrayLiterals": "warn", | ||
"noUnusedVariables": "warn" | ||
}, | ||
"nursery": { | ||
"useSortedClasses": "off", // why-not: eslint-plugin-tailwindcss does this | ||
// ↓ We want to enable this rule, but we can't. Because it doesn't support monorepos at the moment. It's because it can't see the nearest package.json. This issue has been reported to the Issue: https://github.com/biomejs/biome/issues/2010 | ||
// "noUndeclaredDependencies": "error"` | ||
"noDuplicateElseIf": "warn", | ||
"noDuplicateJsonKeys": "warn", | ||
"noEvolvingTypes": "warn", | ||
"noRestrictedImports": { | ||
"level": "warn", | ||
"options": { | ||
"paths": { | ||
"fs": "Use fs/promises instead of fs", | ||
"node:fs": "Use node:fs/promises instead of node:fs", | ||
"dns": "Use dns/promises instead of dns", | ||
"node:dns": "Use node:dns/promises instead of node:dns" | ||
} | ||
} | ||
}, | ||
"noUselessUndefinedInitialization": "warn", | ||
"useConsistentBuiltinInstantiation": "warn", | ||
"useDefaultSwitchClause": "warn", | ||
"useExplicitLengthCheck": "warn" | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { test } from "bun:test"; | ||
import { mkdtemp } from "node:fs/promises"; | ||
import os from "node:os"; | ||
import { dirname } from "node:path"; | ||
import { $, Glob } from "bun"; | ||
|
||
const tomlPattern = new Glob("*/*.toml"); | ||
const tomlPaths = await Array.fromAsync(tomlPattern.scan(".")); | ||
const dirs = tomlPaths.map(dirname); | ||
|
||
test.each(dirs)("proto install %s latest --pin local", async (name) => { | ||
const dir = await mkdtemp(`${os.tmpdir()}/test-${name}-`); | ||
const tomlPath = `${import.meta.dir}/${name}/plugin.toml`; | ||
$.cwd(dir); | ||
console.log(await $`proto plugin add ${name} source:${tomlPath}`.text()); | ||
console.log(await $`proto install ${name} latest --pin local`.text()); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"name": "proto-toml-plugin", | ||
"type": "module", | ||
"devDependencies": { | ||
"@biomejs/biome": "^1.8.1", | ||
"@types/bun": "latest" | ||
}, | ||
"peerDependencies": { | ||
"typescript": "^5.0.0" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
{ | ||
"compilerOptions": { | ||
// Enable latest features | ||
"lib": ["ESNext", "DOM"], | ||
"target": "ESNext", | ||
"module": "ESNext", | ||
"moduleDetection": "force", | ||
"jsx": "react-jsx", | ||
"allowJs": true, | ||
|
||
// Bundler mode | ||
"moduleResolution": "bundler", | ||
"allowImportingTsExtensions": true, | ||
"verbatimModuleSyntax": true, | ||
"noEmit": true, | ||
|
||
// Best practices | ||
"strict": true, | ||
"skipLibCheck": true, | ||
"noFallthroughCasesInSwitch": true, | ||
|
||
// Some stricter flags (disabled by default) | ||
"noUnusedLocals": false, | ||
"noUnusedParameters": false, | ||
"noPropertyAccessFromIndexSignature": false | ||
} | ||
} |