Wa-automate-nodejs: Remove Client.ts from /dist folder

Created on 25 Jul 2020  ·  4Comments  ·  Source: open-wa/wa-automate-nodejs

Describe the bug
While moving my setup to use typescript, since i'm using strict checking/validation, whenever i try to build/watch the project it throws lots of errors because it seems that api/Client.ts is getting packed to dist folder too (i think it probably shouldn't, right?).

Steps to Reproduce
Steps to reproduce the behavior:

  1. Add the project as a dependency (yarn add @open-wa/wa-automate)
  2. Try to build or watch my own project (yarn build/watch)
  3. See errors

Expected behavior
Client.ts should not be there, only compiled (Client.js) version and the Client.d.ts file

Screenshots
Screen Shot 2020-07-25 at 11 57 46

Screen Shot 2020-07-25 at 11 55 46

For now i'm manually removing the .ts file and it works fine!

Regards

All 4 comments

@sandro-salles it is meant to be there but maybe I can rename it without breaking the functionality that requires it to be there. I'll look into it

@github-actions run


⚡ Release! ⚡

(async () => {
function exec(cmd) {
  console.log(execSync(cmd).toString());
}

// Config
const gitUserEmail = "github-actions[bot]@users.noreply.github.com";
const gitUserName = "github-actions[bot]";

exec(`echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" > .npmrc`);
exec(`git config --global user.email "${gitUserEmail}"`);
exec(`git config --global user.name "${gitUserName}"`);
exec(`npm i`);
exec(`npm run release-ci`);

//comment on the issue
var result = execSync(`npx auto-changelog -o ./tempchangelog.txt --commit-limit false --template ./compact-keepachangelog.hbs --stdout`).toString();

    await postComment(result);

//create changelog image
exec(`npm run release-image`);
exec(`git commit -a -m 'updated release-image'`);
exec(`git push --force`);
  })();

Changelog

🚀 Release 1.9.105 (2020-07-25)

  • Release 1.9.105 64759fc
  • puppeteer proxy confirmed to be working #670 495618f
  • fix: remove client.ts from dist to prevent ts errors #676 5374569
  • chore: revert debug info to be logged before process instead of waiting for launch time ms 7cdf7ee
  • chore: Update required node version to >> 12.18.3 [required for proxy to work] [4f6a2a7](https://github.com/open-wa/wa-automate-nodejs/commit/4f6a2a72ce8cfaa6075ecc81e31f2e093ee39059)
  • chore: remove express from devdeps 4affd91

Fixed now! Thanks man 👍

Was this page helpful?
0 / 5 - 0 ratings