Skip to content

Commit

Permalink
fix(rules): add Clickhouse
Browse files Browse the repository at this point in the history
  • Loading branch information
bodinsamuel committed Sep 3, 2023
1 parent e524128 commit b61cf67
Show file tree
Hide file tree
Showing 8 changed files with 34 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ const pkg = JSON.parse(
program
.name('stack-analyser')
.description('CLI to extract metadata from repository')
.argument('<path>', 'repository to analyse', './')
.argument('<path>', 'repository to analyse')
.option('-o, --output <FILENAME>', 'output json to a file', 'output.json')
.option('--flat', 'flatten the output', false)
.version(pkg.version)
Expand Down
1 change: 1 addition & 0 deletions src/rules/__snapshots__/index.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ exports[`all > should match everything 1`] = `
"cassandra",
"circleci",
"cirrusci",
"clickhouse",
"cockroachdb",
"codesandboxci",
"couchbase",
Expand Down
12 changes: 12 additions & 0 deletions src/rules/db/clickhouse.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import { register } from '../../register.js';

register({
tech: 'clickhouse',
name: 'Clickhouse',
type: 'db',
dependencies: [
{ type: 'npm', name: /^@clickhouse\//, example: '@clickhouse/client' },
{ type: 'docker', name: 'clickhouse/clickhouse-server' },
{ type: 'golang', name: 'github.com/ClickHouse/clickhouse-go' },
],
});
1 change: 1 addition & 0 deletions src/rules/db/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import './aws.dynamodb.js';
import './aws.elasticache.js';
import './aws.rds.js';
import './cassandra.js';
import './clickhouse.js';
import './cockroachdb.js';
import './couchbase.js';
import './elasticsearch.js';
Expand Down
6 changes: 6 additions & 0 deletions src/rules/spec/docker/__snapshots__/component.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ exports[`docker > should match everything 1`] = `
"aws.s3",
"caddy",
"cassandra",
"clickhouse",
"couchbase",
"cypressci",
"deno",
Expand Down Expand Up @@ -69,6 +70,11 @@ exports[`docker > should match everything 2`] = `
"cassandra",
"0.0.0",
],
[
"docker",
"clickhouse/clickhouse-server",
"0.0.0",
],
[
"docker",
"couchbase",
Expand Down
6 changes: 6 additions & 0 deletions src/rules/spec/golang/__snapshots__/lockfile.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ exports[`golang (lockfile) > should match everything 1`] = `
"aws.sns",
"aws.sqs",
"azure",
"clickhouse",
"gcp",
"gcp.aiplatform",
"gcp.bigquery",
Expand Down Expand Up @@ -126,6 +127,11 @@ exports[`golang (lockfile) > should match everything 2`] = `
"github.com/Azure/azure-sdk-for-go",
"v1.0.0",
],
[
"golang",
"github.com/ClickHouse/clickhouse-go",
"v1.0.0",
],
[
"golang",
"github.com/aws/aws-sdk-go",
Expand Down
6 changes: 6 additions & 0 deletions src/rules/spec/nodejs/__snapshots__/component.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ exports[`npm > should match everything 1`] = `
"aws.sqs",
"bootstrap",
"browserstack",
"clickhouse",
"couchbase",
"cypressci",
"datadog",
Expand Down Expand Up @@ -196,6 +197,11 @@ exports[`npm > should match everything 2`] = `
"@aws-sdk/middleware-sdk-rds",
"0.0.0",
],
[
"npm",
"@clickhouse/client",
"0.0.0",
],
[
"npm",
"@datadog/cli",
Expand Down
1 change: 1 addition & 0 deletions src/types/techs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ export type AllowedKeys =
| 'cassandra'
| 'circleci'
| 'cirrusci'
| 'clickhouse'
| 'cloudflare'
| 'cockroachdb'
| 'codesandboxci'
Expand Down

0 comments on commit b61cf67

Please sign in to comment.