Skip to content

Commit 5db551e

Browse files
committed
chore: Remove npm i stage from actino, allowing users to use whatever package manager they want i.e. yarn
1 parent de4a68e commit 5db551e

File tree

4 files changed

+13
-21
lines changed

4 files changed

+13
-21
lines changed

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@ jobs:
4343
node-version-file: .node-version
4444
cache: npm
4545

46+
- name: Install dependencies
47+
run: npm ci
48+
4649
- name: Code Quality
4750
uses: ZebraDevs/web-components-code-quality@v1
4851
with:

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/main.ts

Lines changed: 7 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -283,14 +283,13 @@ const getInputs = (
283283
* 1. Check if the environment is local.
284284
* 2. Retrieve inputs based on the environment.
285285
* 3. Change the working directory if specified.
286-
* 4. Install dependencies using npm.
287-
* 5. Generate a Custom Elements Manifest using `npx cem analyze`.
288-
* 6. Run static analysis tools (ESLint, Lit Analyzer, TypeDoc) if enabled.
289-
* 7. Format code using Prettier if enabled.
290-
* 8. Install Playwright browsers and run tests if enabled.
291-
* 9. Calculate and compare code coverage if enabled.
292-
* 10. Check for modified files and update changes in the GitHub repository if any.
293-
* 11. Create a comment on the GitHub pull request with the results if enabled.
286+
* 4. Generate a Custom Elements Manifest using `npx cem analyze`.
287+
* 5. Run static analysis tools (ESLint, Lit Analyzer, TypeDoc) if enabled.
288+
* 6. Format code using Prettier if enabled.
289+
* 7. Install Playwright browsers and run tests if enabled.
290+
* 8. Calculate and compare code coverage if enabled.
291+
* 9. Check for modified files and update changes in the GitHub repository if any.
292+
* 10. Create a comment on the GitHub pull request with the results if enabled.
294293
*/
295294
export async function run(): Promise<void> {
296295
const isLocal = checkIfLocal();
@@ -317,12 +316,6 @@ export async function run(): Promise<void> {
317316
chdir(workingDirectory);
318317
}
319318

320-
// run set up
321-
const npmIStr: StepResponse | undefined = await commandComment({
322-
label: "Install Dependencies",
323-
command: "npm i --ignore-scripts",
324-
});
325-
326319
const cemStr: StepResponse | undefined = await commandComment({
327320
label: "Custom Elements Manifest",
328321
command: "npx cem analyze",
@@ -429,7 +422,6 @@ export async function run(): Promise<void> {
429422
await comment(
430423
getOctokit(token),
431424
context,
432-
npmIStr,
433425
cemStr,
434426
eslintStr,
435427
litAnalyzerStr,

src/scripts/comment.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,6 @@ const li = (str: string): string => {
4848
*
4949
* @param {ReturnType<typeof getOctokit>} ocotokit - The Octokit instance for making GitHub API requests.
5050
* @param {Context} context - The context of the GitHub action, including issue and repository information.
51-
* @param {StepResponse | undefined} npmIStr - The result of the npm install step.
5251
* @param {StepResponse | undefined} cemStr - The result of the custom element manifest step.
5352
* @param {StepResponse | undefined} eslintStr - The result of the ESLint step.
5453
* @param {StepResponse | undefined} litAnalyzerStr - The result of the Lit Analyzer step.
@@ -64,7 +63,6 @@ const li = (str: string): string => {
6463
export const comment = async (
6564
ocotokit: ReturnType<typeof getOctokit>,
6665
context: Context,
67-
npmIStr: StepResponse | undefined,
6866
cemStr: StepResponse | undefined,
6967
eslintStr: StepResponse | undefined,
7068
litAnalyzerStr: StepResponse | undefined,
@@ -82,7 +80,6 @@ export const comment = async (
8280
let formatting = [];
8381
let testing = [];
8482
let postChecks = [];
85-
if (npmIStr !== undefined) setup.push(npmIStr);
8683
if (cemStr !== undefined) setup.push(cemStr);
8784
if (eslintStr !== undefined) analysis.push(eslintStr);
8885
if (litAnalyzerStr !== undefined) analysis.push(litAnalyzerStr);
@@ -108,7 +105,7 @@ ${group("Post Checks", postChecks, false)}
108105
owner: context.repo.owner,
109106
repo: context.repo.repo,
110107
});
111-
const comment = comments.find((comment) =>
108+
const comment = comments.find((comment: any) =>
112109
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
113110
comment.body!.includes("PR Checks Complete"),
114111
);

0 commit comments

Comments
 (0)