Skip to content

Commit

Permalink
create to ship workflow at updating egg.yaml.
Browse files Browse the repository at this point in the history
lint. update README.
  • Loading branch information
yoshixmk committed Aug 9, 2020
1 parent 3e51666 commit 5f56c4c
Show file tree
Hide file tree
Showing 8 changed files with 124 additions and 14 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Lint

on: [push, pull_request]

jobs:
fmt:
name: deno fmt

runs-on: ubuntu-latest
timeout-minutes: 60

steps:
- name: Setup repo
uses: actions/checkout@v2

- name: Setup Deno
uses: denolib/setup-deno@v2

- name: Check formatting
run: deno fmt --check

lint:
name: deno lint

runs-on: ubuntu-latest
timeout-minutes: 60

steps:
- name: Setup repo
uses: actions/checkout@v2

- name: Setup Deno
uses: denolib/setup-deno@v2

- name: Run linter
run: deno lint --unstable **/*.ts
24 changes: 24 additions & 0 deletions .github/workflows/ship.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Ship

on:
workflow_dispatch:
inputs:
version:
description: "Version"
required: true


jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Setup repo
uses: actions/checkout@v2

- name: Setup Deno
uses: denolib/setup-deno@v2

- name: Publish module
run: |
deno run -A --unstable https://x.nest.land/eggs@0.2.1/mod.ts link ${{ secrets.NESTAPIKEY }}
deno run -A --unstable https://x.nest.land/eggs@0.2.1/mod.ts publish --version ${{ github.event.inputs.tags }}
52 changes: 52 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Test

on:
push:
pull_request:
schedule:
- cron: "0 10 * * *"

jobs:
stable:
name: Deno Stable

runs-on: ${{ matrix.os }}
timeout-minutes: 60

strategy:
fail-fast: false
matrix:
os: [macOS-latest, windows-latest, ubuntu-latest]

steps:
- name: Setup repo
uses: actions/checkout@v2

- name: Setup Deno
uses: denolib/setup-deno@v2

- name: Run tests
run: deno test --allow-read --allow-env --allow-net

nightly:
name: Deno Nightly

runs-on: ${{ matrix.os }}
timeout-minutes: 60

strategy:
fail-fast: false
matrix:
os: [macOS-latest, windows-latest, ubuntu-latest]

steps:
- name: Setup repo
uses: actions/checkout@v2

- name: Setup Deno
uses: denolib/setup-deno@v2
with:
deno-version: nightly

- name: Run tests
run: deno test --allow-read --allow-env --allow-net
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# deno-x-ranking
[![(Deno)](https://img.shields.io/badge/deno-v1.1.3-green.svg?style=flat-square&logo=deno)](https://deno.land)
[![(Deno)](https://img.shields.io/badge/deno-^1.2.0-green.svg?style=flat-square&logo=deno)](https://deno.land)
![gh-pages](https://github.com/yoshixmk/deno-x-ranking/workflows/gh-pages/badge.svg)
[![nest badge](https://nest.land/badge.svg)](https://nest.land/package/ranking)

Expand Down
12 changes: 6 additions & 6 deletions deps.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,21 @@ export { encode } from "https://deno.land/std@0.61.0/encoding/base64.ts";
export {
Markdown,
link,
} from "https://deno.land/x/deno_markdown/mod.ts";
} from "https://deno.land/x/deno_markdown@0.3/mod.ts";

export { green, red } from "https://deno.land/std@0.61.0/fmt/colors.ts";
export { args } from "https://deno.land/x/args@2.0.2/wrapper.ts";
export { green, red } from "https://deno.land/std@0.64.0/fmt/colors.ts";
export { args } from "https://deno.land/x/args@2.0.7/wrapper.ts";
export {
EarlyExitFlag,
PartialOption,
Option,
} from "https://deno.land/x/args@2.0.2/flag-types.ts";
} from "https://deno.land/x/args@2.0.7/flag-types.ts";
export {
FiniteNumber,
Choice,
Text,
} from "https://deno.land/x/args@2.0.2/value-types.ts";
} from "https://deno.land/x/args@2.0.7/value-types.ts";
export {
PARSE_FAILURE,
} from "https://deno.land/x/args@2.0.2/symbols.ts";
} from "https://deno.land/x/args@2.0.7/symbols.ts";
export { coffee };
5 changes: 3 additions & 2 deletions egg.yaml
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
name: ranking
description: Deno Third Party Modules Ranking
version: 0.0.2
stable: false
# version: <Selected version on workflow>
stable: true
entry: ./mod.ts
unlisted: false
fmt: true
repository: https://github.com/yoshixmk/deno-x-ranking
files:
- ./*.ts
- ./src/**/*.ts
- ./config
- README.md
5 changes: 1 addition & 4 deletions src/domains/github_database_entry.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
interface Entry {
}

export interface GithubEntry extends Entry {
export interface GithubEntry {
repository: string; // Github repository
latestVersion: string;
}
Expand Down
2 changes: 1 addition & 1 deletion src/services/registry_service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class RegistryService {
}

public async getGithubEntries(
sampling: string = "false",
sampling: string,
): Promise<GithubEntries> {
const modules = await fetchAll();
const moduleNames = modules
Expand Down

0 comments on commit 5f56c4c

Please sign in to comment.