Skip to content

Commit

Permalink
Revert single quote application
Browse files Browse the repository at this point in the history
  • Loading branch information
thyeggman committed Oct 14, 2022
1 parent 168b6b5 commit fb63e63
Show file tree
Hide file tree
Showing 74 changed files with 619 additions and 622 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build-preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2-beta
with:
node-version: '12'
node-version: "12"
- run: rm package-lock.json
- run: npm --no-git-tag-version version 1.0.${{ github.run_number }}
- run: npm install
Expand All @@ -22,7 +22,7 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: 'build-${{ github.run_number }}'
tag_name: "build-${{ github.run_number }}"
release_name: Nightly Build ${{ github.run_number }}
draft: false
prerelease: false
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/manual.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ on:
inputs:
name:
# Friendly description to be shown in the UI instead of 'name'
description: 'Person to greet'
description: "Person to greet"
# Default value if no value is explicitly provided
default: 'World'
default: "World"
# Input has to be provided for the workflow to run
required: true

Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
inputs:
version:
required: true
description: 'Version to bump `package.json` to (format: x.y.z)'
description: "Version to bump `package.json` to (format: x.y.z)"

jobs:
build:
Expand All @@ -18,7 +18,7 @@ jobs:
git config --global user.name "Christopher Schleiden"
- uses: actions/setup-node@v2
with:
node-version: '12'
node-version: "12"
- run: npm version ${{ github.event.inputs.version }}
- run: npm install
- run: npm run package
Expand All @@ -28,8 +28,8 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: 'release-v${{ github.event.inputs.version }}'
release_name: 'v${{ github.event.inputs.version }}'
tag_name: "release-v${{ github.event.inputs.version }}"
release_name: "v${{ github.event.inputs.version }}"
draft: false
prerelease: false
- name: Upload Release Asset
Expand All @@ -48,5 +48,5 @@ jobs:
pat: ${{ secrets.PUBLISHER_KEY }}
registryUrl: https://marketplace.visualstudio.com
extensionFile: ./vscode-github-actions-${{ github.event.inputs.version }}.vsix
packagePath: ''
packagePath: ""
- run: git push
10 changes: 5 additions & 5 deletions .github/workflows/stale.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Mark stale issues and pull requests

on:
schedule:
- cron: '47 2 * * *'
- cron: "47 2 * * *"

jobs:
stale:
Expand All @@ -12,8 +12,8 @@ jobs:
- uses: actions/stale@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-issue-message: 'This issue is stale due to inactivity'
stale-pr-message: 'This PR is stale due to inactivity'
stale-issue-label: 'stale'
stale-pr-label: 'stale'
stale-issue-message: "This issue is stale due to inactivity"
stale-pr-message: "This PR is stale due to inactivity"
stale-issue-label: "stale"
stale-pr-label: "stale"
days-before-stale: 120
2 changes: 1 addition & 1 deletion .prettierrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"tabWidth": 2,
"useTabs": false,
"printWidth": 120,
"singleQuote": true,
"singleQuote": false,
"bracketSpacing": false,
"trailingComma": "none",
"arrowParens": "avoid"
Expand Down
2 changes: 1 addition & 1 deletion @types/ssh-config.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
* ConfigResolvers take a config, resolve some additional data (perhaps using
* a config file), and return a new Config.
*/
declare module 'ssh-config' {
declare module "ssh-config" {
export type ConfigResolver = (config: Config) => Config;

export type Config = Record<string, string>;
Expand Down
6 changes: 3 additions & 3 deletions src/api/api.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import {Octokit} from '@octokit/rest';
import {Octokit} from "@octokit/rest";

export function getClient(token: string): Octokit {
return new Octokit({
auth: token,
userAgent: 'VS Code GitHub Actions',
previews: ['jane-hopper']
userAgent: "VS Code GitHub Actions",
previews: ["jane-hopper"]
});
}
16 changes: 8 additions & 8 deletions src/auth/auth.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import * as vscode from 'vscode';
import * as vscode from "vscode";

import {orgFeaturesEnabled, updateOrgFeaturesEnabled} from '../configuration/configuration';
import {orgFeaturesEnabled, updateOrgFeaturesEnabled} from "../configuration/configuration";

import {resetGitHubContext} from '../git/repository';
import {resetGitHubContext} from "../git/repository";

const AUTH_PROVIDER_ID = 'github';
const DEFAULT_SCOPES = ['repo', 'workflow'];
const ORG_SCOPES = [...DEFAULT_SCOPES, 'admin:org'];
const AUTH_PROVIDER_ID = "github";
const DEFAULT_SCOPES = ["repo", "workflow"];
const ORG_SCOPES = [...DEFAULT_SCOPES, "admin:org"];

export function registerListeners(context: vscode.ExtensionContext): void {
context.subscriptions.push(
Expand All @@ -24,7 +24,7 @@ export async function getSession(): Promise<vscode.AuthenticationSession> {
});

if (!existingSession) {
throw new Error('Could not get token from the GitHub authentication provider. \nPlease sign-in and allow access.');
throw new Error("Could not get token from the GitHub authentication provider. \nPlease sign-in and allow access.");
}

return existingSession;
Expand All @@ -36,7 +36,7 @@ export async function enableOrgFeatures() {
await resetGitHubContext();

// TODO: CS: There has be a better way :)
await vscode.commands.executeCommand('github-actions.explorer.refresh');
await vscode.commands.executeCommand("github-actions.explorer.refresh");
}

function getScopes(): string[] {
Expand Down
4 changes: 2 additions & 2 deletions src/client/client.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import {Octokit} from '@octokit/rest';
import {getClient as getAPIClient} from '../api/api';
import {Octokit} from "@octokit/rest";
import {getClient as getAPIClient} from "../api/api";

export function getClient(token: string): Octokit {
return getAPIClient(token);
Expand Down
10 changes: 5 additions & 5 deletions src/commands/cancelWorkflowRun.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import * as vscode from 'vscode';
import {GitHubRepoContext} from '../git/repository';
import {WorkflowRun} from '../model';
import * as vscode from "vscode";
import {GitHubRepoContext} from "../git/repository";
import {WorkflowRun} from "../model";

interface CancelWorkflowRunLogsCommandArgs {
gitHubRepoContext: GitHubRepoContext;
Expand All @@ -10,7 +10,7 @@ interface CancelWorkflowRunLogsCommandArgs {
export function registerCancelWorkflowRun(context: vscode.ExtensionContext) {
context.subscriptions.push(
vscode.commands.registerCommand(
'github-actions.workflow.run.cancel',
"github-actions.workflow.run.cancel",
async (args: CancelWorkflowRunLogsCommandArgs) => {
const gitHubContext = args.gitHubRepoContext;
const run = args.run;
Expand All @@ -25,7 +25,7 @@ export function registerCancelWorkflowRun(context: vscode.ExtensionContext) {
await vscode.window.showErrorMessage(`Could not cancel workflow: '${(e as Error).message}'`);
}

await vscode.commands.executeCommand('github-actions.explorer.refresh');
await vscode.commands.executeCommand("github-actions.explorer.refresh");
}
)
);
Expand Down
10 changes: 5 additions & 5 deletions src/commands/openWorkflowFile.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import * as vscode from 'vscode';
import * as vscode from "vscode";

import {GitHubRepoContext} from '../git/repository';
import {Workflow} from '../model';
import {getWorkflowUri} from '../workflow/workflow';
import {GitHubRepoContext} from "../git/repository";
import {Workflow} from "../model";
import {getWorkflowUri} from "../workflow/workflow";

interface OpenWorkflowCommandArgs {
gitHubRepoContext: GitHubRepoContext;
Expand All @@ -12,7 +12,7 @@ interface OpenWorkflowCommandArgs {
export function registerOpenWorkflowFile(context: vscode.ExtensionContext) {
context.subscriptions.push(
vscode.commands.registerCommand(
'github-actions.explorer.openWorkflowFile',
"github-actions.explorer.openWorkflowFile",
async (args: OpenWorkflowCommandArgs) => {
const {wf, gitHubRepoContext} = args;

Expand Down
6 changes: 3 additions & 3 deletions src/commands/openWorkflowRun.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import * as vscode from 'vscode';
import {WorkflowRun} from '../model';
import * as vscode from "vscode";
import {WorkflowRun} from "../model";

interface OpenWorkflowRunCommandArgs {
run: WorkflowRun;
}

export function registerOpenWorkflowRun(context: vscode.ExtensionContext) {
context.subscriptions.push(
vscode.commands.registerCommand('github-actions.workflow.run.open', async (args: OpenWorkflowRunCommandArgs) => {
vscode.commands.registerCommand("github-actions.workflow.run.open", async (args: OpenWorkflowRunCommandArgs) => {
const run = args.run;
const url = run.html_url;
await vscode.env.openExternal(vscode.Uri.parse(url));
Expand Down
16 changes: 8 additions & 8 deletions src/commands/openWorkflowRunLogs.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import * as vscode from 'vscode';
import {GitHubRepoContext} from '../git/repository';
import {updateDecorations} from '../logs/formatProvider';
import {getLogInfo} from '../logs/logInfoProvider';
import {buildLogURI} from '../logs/scheme';
import {WorkflowJob, WorkflowStep} from '../model';
import * as vscode from "vscode";
import {GitHubRepoContext} from "../git/repository";
import {updateDecorations} from "../logs/formatProvider";
import {getLogInfo} from "../logs/logInfoProvider";
import {buildLogURI} from "../logs/scheme";
import {WorkflowJob, WorkflowStep} from "../model";

export interface OpenWorkflowRunLogsCommandArgs {
gitHubRepoContext: GitHubRepoContext;
Expand All @@ -13,7 +13,7 @@ export interface OpenWorkflowRunLogsCommandArgs {

export function registerOpenWorkflowRunLogs(context: vscode.ExtensionContext) {
context.subscriptions.push(
vscode.commands.registerCommand('github-actions.workflow.logs', async (args: OpenWorkflowRunLogsCommandArgs) => {
vscode.commands.registerCommand("github-actions.workflow.logs", async (args: OpenWorkflowRunLogsCommandArgs) => {
const gitHubRepoContext = args.gitHubRepoContext;
const job = args.job;
const step = args.step;
Expand All @@ -31,7 +31,7 @@ export function registerOpenWorkflowRunLogs(context: vscode.ExtensionContext) {

const logInfo = getLogInfo(uri);
if (!logInfo) {
throw new Error('Could not get log info');
throw new Error("Could not get log info");
}

// Custom formatting after the editor has been opened
Expand Down
6 changes: 3 additions & 3 deletions src/commands/orgLogin.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import * as vscode from 'vscode';
import * as vscode from "vscode";

import {enableOrgFeatures} from '../auth/auth';
import {enableOrgFeatures} from "../auth/auth";

export function registerOrgLogin(context: vscode.ExtensionContext) {
context.subscriptions.push(
vscode.commands.registerCommand('github-actions.auth.org-login', async () => {
vscode.commands.registerCommand("github-actions.auth.org-login", async () => {
await enableOrgFeatures();
})
);
Expand Down
14 changes: 7 additions & 7 deletions src/commands/pinWorkflow.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import * as vscode from 'vscode';
import * as vscode from "vscode";

import {GitHubRepoContext} from '../git/repository';
import {Workflow} from '../model';
import {getWorkflowUri} from '../workflow/workflow';
import {pinWorkflow} from '../configuration/configuration';
import {GitHubRepoContext} from "../git/repository";
import {Workflow} from "../model";
import {getWorkflowUri} from "../workflow/workflow";
import {pinWorkflow} from "../configuration/configuration";

interface PinWorkflowCommandOptions {
gitHubRepoContext: GitHubRepoContext;
Expand All @@ -14,7 +14,7 @@ interface PinWorkflowCommandOptions {

export function registerPinWorkflow(context: vscode.ExtensionContext) {
context.subscriptions.push(
vscode.commands.registerCommand('github-actions.workflow.pin', async (args: PinWorkflowCommandOptions) => {
vscode.commands.registerCommand("github-actions.workflow.pin", async (args: PinWorkflowCommandOptions) => {
const {gitHubRepoContext, wf} = args;

if (!wf) {
Expand All @@ -30,7 +30,7 @@ export function registerPinWorkflow(context: vscode.ExtensionContext) {
await pinWorkflow(relativeWorkflowPath);

args.updateContextValue();
await vscode.commands.executeCommand('github-actions.explorer.refresh');
await vscode.commands.executeCommand("github-actions.explorer.refresh");
})
);
}
10 changes: 5 additions & 5 deletions src/commands/rerunWorkflowRun.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import * as vscode from 'vscode';
import * as vscode from "vscode";

import {GitHubRepoContext} from '../git/repository';
import {WorkflowRun} from '../model';
import {GitHubRepoContext} from "../git/repository";
import {WorkflowRun} from "../model";

interface ReRunWorkflowRunLogsCommandArgs {
gitHubRepoContext: GitHubRepoContext;
Expand All @@ -11,7 +11,7 @@ interface ReRunWorkflowRunLogsCommandArgs {
export function registerReRunWorkflowRun(context: vscode.ExtensionContext) {
context.subscriptions.push(
vscode.commands.registerCommand(
'github-actions.workflow.run.rerun',
"github-actions.workflow.run.rerun",
async (args: ReRunWorkflowRunLogsCommandArgs) => {
const gitHubContext = args.gitHubRepoContext;
const run = args.run;
Expand All @@ -26,7 +26,7 @@ export function registerReRunWorkflowRun(context: vscode.ExtensionContext) {
await vscode.window.showErrorMessage(`Could not rerun workflow: '${(e as Error).message}'`);
}

await vscode.commands.executeCommand('github-actions.explorer.refresh');
await vscode.commands.executeCommand("github-actions.explorer.refresh");
}
)
);
Expand Down
14 changes: 7 additions & 7 deletions src/commands/secrets/addSecret.ts
Original file line number Diff line number Diff line change
@@ -1,26 +1,26 @@
import * as vscode from 'vscode';
import {GitHubRepoContext} from '../../git/repository';
import {encodeSecret} from '../../secrets';
import * as vscode from "vscode";
import {GitHubRepoContext} from "../../git/repository";
import {encodeSecret} from "../../secrets";

interface AddSecretCommandArgs {
gitHubRepoContext: GitHubRepoContext;
}

export function registerAddSecret(context: vscode.ExtensionContext) {
context.subscriptions.push(
vscode.commands.registerCommand('github-actions.settings.secret.add', async (args: AddSecretCommandArgs) => {
vscode.commands.registerCommand("github-actions.settings.secret.add", async (args: AddSecretCommandArgs) => {
const gitHubContext = args.gitHubRepoContext;

const name = await vscode.window.showInputBox({
prompt: 'Enter name for new secret'
prompt: "Enter name for new secret"
});

if (!name) {
return;
}

const value = await vscode.window.showInputBox({
prompt: 'Enter the new secret value'
prompt: "Enter the new secret value"
});

if (value) {
Expand All @@ -45,7 +45,7 @@ export function registerAddSecret(context: vscode.ExtensionContext) {
}
}

await vscode.commands.executeCommand('github-actions.explorer.refresh');
await vscode.commands.executeCommand("github-actions.explorer.refresh");
})
);
}
Loading

0 comments on commit fb63e63

Please sign in to comment.