Dagger
Search

staydevops-ts

No long description provided.

Installation

dagger install github.com/StaytunedLLP/daggerverse@d508005210c271a66eaa0c03f548f2876dd5fb47

Entrypoint

Return Type
StaydevopsTs
Example
dagger -m github.com/StaytunedLLP/daggerverse@d508005210c271a66eaa0c03f548f2876dd5fb47 call \
func (m *MyModule) Example() *dagger.StaydevopsTs  {
	return dag.
			StaydevopsTs()
}
@function
def example() -> dagger.StaydevopsTs:
	return (
		dag.staydevops_ts()
	)
@func()
example(): StaydevopsTs {
	return dag
		.staydevopsTs()
}

Types

StaydevopsTs 🔗

Shared Dagger module for Node/TypeScript repository checks and deployment helpers.

checks() 🔗

Returns the collection of repository checks.

Return Type
StaydevopsTsChecks !
Example
dagger -m github.com/StaytunedLLP/daggerverse@d508005210c271a66eaa0c03f548f2876dd5fb47 call \
 checks
func (m *MyModule) Example() *dagger.StaydevopsTsChecks  {
	return dag.
			StaydevopsTs().
			Checks()
}
@function
def example() -> dagger.StaydevopsTsChecks:
	return (
		dag.staydevops_ts()
		.checks()
	)
@func()
example(): StaydevopsTsChecks {
	return dag
		.staydevopsTs()
		.checks()
}

testPlaywright() 🔗

Run Playwright E2E tests for a package inside the provided source tree.

Return Type
String !
Arguments
NameTypeDefault ValueDescription
sourceDirectory -- Repository source directory containing Playwright tests.
nodeAuthTokenSecret -- Optional GitHub Packages token secret. Required only when installing private npm packages.
packagePathsString !"."- Package path or comma-separated package paths relative to the source root. The first path is used for build/test execution.
testSelectorString !""- Optional selector/path passed to the npm test script using `--`.
testScriptString !"test:e2e"- Npm script to run for tests. Defaults to `test:e2e`.
runBuildBoolean !true- When true, runs `npm run build` before executing tests.
registryScopeString !"staytunedllp"- GitHub Packages scope used when authenticating npm.
browsersString !"chromium"- Browser list for Playwright install commands, as a comma-separated string.
runAffectedBoolean !false- When true, resolves affected tests from git diff and runs only those selectors.
baseString !"origin/main"- Base ref used by affected discovery when `runAffected` is enabled.
listOnlyBoolean !false- When true with `runAffected`, returns discovered selectors without running build/tests.
changedFilesString !""- Optional whitespace/comma-separated file list used instead of git diff in affected discovery.
Example
dagger -m github.com/StaytunedLLP/daggerverse@d508005210c271a66eaa0c03f548f2876dd5fb47 call \
 test-playwright --package-paths string --test-selector string --test-script string --run-build boolean --registry-scope string --browsers string --run-affected boolean --base string --list-only boolean --changed-files string
func (m *MyModule) Example(ctx context.Context, packagePaths string, testSelector string, testScript string, runBuild bool, registryScope string, browsers string, runAffected bool, base string, listOnly bool, changedFiles string) string  {
	return dag.
			StaydevopsTs().
			TestPlaywright(ctxpackagePaths, testSelector, testScript, runBuild, registryScope, browsers, runAffected, base, listOnly, changedFiles)
}
@function
async def example(package_paths: str, test_selector: str, test_script: str, run_build: bool, registry_scope: str, browsers: str, run_affected: bool, base: str, list_only: bool, changed_files: str) -> str:
	return await (
		dag.staydevops_ts()
		.test_playwright(package_paths, test_selector, test_script, run_build, registry_scope, browsers, run_affected, base, list_only, changed_files)
	)
@func()
async example(packagePaths: string, testSelector: string, testScript: string, runBuild: boolean, registryScope: string, browsers: string, runAffected: boolean, base: string, listOnly: boolean, changedFiles: string): Promise<string> {
	return dag
		.staydevopsTs()
		.testPlaywright(packagePaths, testSelector, testScript, runBuild, registryScope, browsers, runAffected, base, listOnly, changedFiles)
}

gitDiff() 🔗

Retrieves an array of changed files based on the specified mode.

Return Type
[String ! ] !
Arguments
NameTypeDefault ValueDescription
sourceDirectory -- The source directory to check for changed files.
modeString !"staged"- The diff mode to use: 'staged', 'previous', or 'between'.
commitRangeString !""- A string specifying the range of commits (required for 'between' mode).
Example
dagger -m github.com/StaytunedLLP/daggerverse@d508005210c271a66eaa0c03f548f2876dd5fb47 call \
 git-diff --mode string --commit-range string
func (m *MyModule) Example(ctx context.Context, mode string, commitRange string) []string  {
	return dag.
			StaydevopsTs().
			GitDiff(ctxmode, commitRange)
}
@function
async def example(mode: str, commit_range: str) -> List[str]:
	return await (
		dag.staydevops_ts()
		.git_diff(mode, commit_range)
	)
@func()
async example(mode: string, commitRange: string): Promise<string[]> {
	return dag
		.staydevopsTs()
		.gitDiff(mode, commitRange)
}

fbApphosting() 🔗

Performs actions on Firebase App Hosting backends.

Return Type
String !
Arguments
NameTypeDefault ValueDescription
actionString !-- The action to perform: 'deploy' or 'delete'.
projectIdString !-- Firebase project ID used for deployment.
backendIdString !-- Firebase App Hosting backend identifier.
sourceDirectory -- Repository source directory containing the application to deploy (required for deploy).
rootDirString !"."- Application root directory inside the source tree (deploy only).
appIdString !""- Optional Firebase app ID used when creating a backend (deploy only).
regionString !"asia-southeast1"- Firebase App Hosting region (deploy only).
gcpCredentialsSecret -- Optional GCP service account secret.
wifProviderString !""- Workload Identity Federation provider resource name (deploy only).
wifServiceAccountString !""- Workload Identity Federation service account email (deploy only).
wifOidcTokenSecret -- Optional OIDC token secret for WIF authentication (deploy only).
wifAudienceString !""- Optional WIF audience override (deploy only).
Example
dagger -m github.com/StaytunedLLP/daggerverse@d508005210c271a66eaa0c03f548f2876dd5fb47 call \
 fb-apphosting --action string --project-id string --backend-id string --root-dir string --app-id string --region string --wif-provider string --wif-service-account string --wif-audience string
func (m *MyModule) Example(ctx context.Context, action string, projectId string, backendId string, rootDir string, appId string, region string, wifProvider string, wifServiceAccount string, wifAudience string) string  {
	return dag.
			StaydevopsTs().
			FbApphosting(ctx, action, projectId, backendId, rootDir, appId, region, wifProvider, wifServiceAccount, wifAudience)
}
@function
async def example(action: str, project_id: str, backend_id: str, root_dir: str, app_id: str, region: str, wif_provider: str, wif_service_account: str, wif_audience: str) -> str:
	return await (
		dag.staydevops_ts()
		.fb_apphosting(action, project_id, backend_id, root_dir, app_id, region, wif_provider, wif_service_account, wif_audience)
	)
@func()
async example(action: string, projectId: string, backendId: string, rootDir: string, appId: string, region: string, wifProvider: string, wifServiceAccount: string, wifAudience: string): Promise<string> {
	return dag
		.staydevopsTs()
		.fbApphosting(action, projectId, backendId, rootDir, appId, region, wifProvider, wifServiceAccount, wifAudience)
}

fbWebhosting() 🔗

Build and deploy a Firebase web hosting project from the provided source tree.

Return Type
String !
Arguments
NameTypeDefault ValueDescription
sourceDirectory -- Repository source directory containing the Firebase project and any frontend or backend packages.
projectIdString !-- Firebase project ID used for the deploy command and frontend environment generation.
gcpCredentialsSecret !-- GCP service account JSON secret used for Firebase deployment authentication.
appIdString -- Optional Firebase app ID to inject into frontend environment variables before building.
onlyString -- Optional Firebase deploy target selector passed to `firebase deploy --only`.
frontendDirString -- Optional frontend package directory to build before deployment, relative to the source root.
backendDirString -- Optional backend or secondary package directory whose dependencies should be installed before deployment.
firebaseDirString -- Optional directory containing `firebase.json`. Defaults to the workspace root.
webappConfigSecret -- Optional secret containing Firebase web app config JSON to write into frontend environment variables.
extraEnvSecret -- Optional secret containing extra `.env` lines appended before the frontend build runs.
nodeAuthTokenSecret -- Optional GitHub Packages token secret. Required only when frontend or backend installs private npm packages.
Example
dagger -m github.com/StaytunedLLP/daggerverse@d508005210c271a66eaa0c03f548f2876dd5fb47 call \
 fb-webhosting --project-id string --gcp-credentials env:MYSECRET
func (m *MyModule) Example(ctx context.Context, projectId string, gcpCredentials *dagger.Secret) string  {
	return dag.
			StaydevopsTs().
			FbWebhosting(ctxprojectId, gcpCredentials)
}
@function
async def example(project_id: str, gcp_credentials: dagger.Secret) -> str:
	return await (
		dag.staydevops_ts()
		.fb_webhosting(project_id, gcp_credentials)
	)
@func()
async example(projectId: string, gcpCredentials: Secret): Promise<string> {
	return dag
		.staydevopsTs()
		.fbWebhosting(projectId, gcpCredentials)
}

publishPackage() 🔗

Deterministic package publishing logic for npm packages. For merged release PRs, this also creates the GitHub Release after publishing the npm package and can finalize release labels.

Return Type
String !
Arguments
NameTypeDefault ValueDescription
sourceDirectory -- Repository source directory to publish from.
refString !-- Git ref triggering the workflow (e.g. refs/tags/v1.2.3 for release events).
eventNameString !-- GitHub event name (allowed: release, workflow_dispatch).
githubTokenSecret !-- GitHub PAT for npm authentication and PR validation.
repoOwnerString !-- Repository owner (e.g. StaytunedLLP).
repoNameString !-- Repository name (e.g. devops).
inputBranchString -- Manual branch input provided for workflow_dispatch.
releasePrNumberInteger -- Release PR number to finalize after publishing a merged release commit.
registryScopeString -- The scope of the npm package (e.g. staytunedllp).
Example
dagger -m github.com/StaytunedLLP/daggerverse@d508005210c271a66eaa0c03f548f2876dd5fb47 call \
 publish-package --ref string --event-name string --github-token env:MYSECRET --repo-owner string --repo-name string
func (m *MyModule) Example(ctx context.Context, ref string, eventName string, githubToken *dagger.Secret, repoOwner string, repoName string) string  {
	return dag.
			StaydevopsTs().
			PublishPackage(ctxref, eventName, githubToken, repoOwner, repoName)
}
@function
async def example(ref: str, event_name: str, github_token: dagger.Secret, repo_owner: str, repo_name: str) -> str:
	return await (
		dag.staydevops_ts()
		.publish_package(ref, event_name, github_token, repo_owner, repo_name)
	)
@func()
async example(ref: string, eventName: string, githubToken: Secret, repoOwner: string, repoName: string): Promise<string> {
	return dag
		.staydevopsTs()
		.publishPackage(ref, eventName, githubToken, repoOwner, repoName)
}

StaydevopsTsChecks 🔗

Collection of repository checks and validation tools.

install() 🔗

Install Node dependencies and optionally provision Playwright and Firebase tooling.

Return Type
Directory !
Arguments
NameTypeDefault ValueDescription
sourceDirectory -- Repository source directory to install into the workspace container.
nodeAuthTokenSecret -- Optional GitHub Packages token secret. Required only when installing private npm packages.
packagePathsString !"."- Package path or comma-separated package paths relative to the source root where npm installs should run.
playwrightInstallBoolean !false- When true, installs Playwright system dependencies and Chromium into the prepared workspace.
firebaseToolsBoolean !false- When true, installs Firebase CLI tooling in the prepared workspace container.
Example
dagger -m github.com/StaytunedLLP/daggerverse@d508005210c271a66eaa0c03f548f2876dd5fb47 call \
 checks \
 install --package-paths string --playwright-install boolean --firebase-tools boolean
func (m *MyModule) Example(packagePaths string, playwrightInstall bool, firebaseTools bool) *dagger.Directory  {
	return dag.
			StaydevopsTs().
			Checks().
			Install(packagePaths, playwrightInstall, firebaseTools)
}
@function
def example(package_paths: str, playwright_install: bool, firebase_tools: bool) -> dagger.Directory:
	return (
		dag.staydevops_ts()
		.checks()
		.install(package_paths, playwright_install, firebase_tools)
	)
@func()
example(packagePaths: string, playwrightInstall: boolean, firebaseTools: boolean): Directory {
	return dag
		.staydevopsTs()
		.checks()
		.install(packagePaths, playwrightInstall, firebaseTools)
}

format() 🔗

Run the repository formatting check with npm run format:check.

Return Type
Void !
Arguments
NameTypeDefault ValueDescription
sourceDirectory -- Repository source directory to validate.
Example
dagger -m github.com/StaytunedLLP/daggerverse@d508005210c271a66eaa0c03f548f2876dd5fb47 call \
 checks \
 format
func (m *MyModule) Example(ctx context.Context)   {
	return dag.
			StaydevopsTs().
			Checks().
			Format(ctx)
}
@function
async def example() -> None:
	return await (
		dag.staydevops_ts()
		.checks()
		.format()
	)
@func()
async example(): Promise<void> {
	return dag
		.staydevopsTs()
		.checks()
		.format()
}

lint() 🔗

Run the repository linter with npm run lint.

Return Type
Void !
Arguments
NameTypeDefault ValueDescription
sourceDirectory -- Repository source directory to lint.
Example
dagger -m github.com/StaytunedLLP/daggerverse@d508005210c271a66eaa0c03f548f2876dd5fb47 call \
 checks \
 lint
func (m *MyModule) Example(ctx context.Context)   {
	return dag.
			StaydevopsTs().
			Checks().
			Lint(ctx)
}
@function
async def example() -> None:
	return await (
		dag.staydevops_ts()
		.checks()
		.lint()
	)
@func()
async example(): Promise<void> {
	return dag
		.staydevopsTs()
		.checks()
		.lint()
}

build() 🔗

Run the repository build with npm run build.

Return Type
Void !
Arguments
NameTypeDefault ValueDescription
sourceDirectory -- Repository source directory to build.
Example
dagger -m github.com/StaytunedLLP/daggerverse@d508005210c271a66eaa0c03f548f2876dd5fb47 call \
 checks \
 build
func (m *MyModule) Example(ctx context.Context)   {
	return dag.
			StaydevopsTs().
			Checks().
			Build(ctx)
}
@function
async def example() -> None:
	return await (
		dag.staydevops_ts()
		.checks()
		.build()
	)
@func()
async example(): Promise<void> {
	return dag
		.staydevopsTs()
		.checks()
		.build()
}

test() 🔗

Run the repository test suite with npm run test.

Return Type
Void !
Arguments
NameTypeDefault ValueDescription
sourceDirectory -- Repository source directory to test.
Example
dagger -m github.com/StaytunedLLP/daggerverse@d508005210c271a66eaa0c03f548f2876dd5fb47 call \
 checks \
 test
func (m *MyModule) Example(ctx context.Context)   {
	return dag.
			StaydevopsTs().
			Checks().
			Test(ctx)
}
@function
async def example() -> None:
	return await (
		dag.staydevops_ts()
		.checks()
		.test()
	)
@func()
async example(): Promise<void> {
	return dag
		.staydevopsTs()
		.checks()
		.test()
}