apexdox-vs-code icon indicating copy to clipboard operation
apexdox-vs-code copied to clipboard

CLI option for CI

Open aranwe opened this issue 5 years ago • 9 comments

Hi,

It would be great to be able to run apexdox from CLI in node.js to include it in our CI scripts. :) Though there seems to be quite a few vscode imports throughout the codebase.

What do you think? :)

Thanks for the good job! & cheers, O.

aranwe avatar Dec 11 '19 14:12 aranwe

Hey @aranwe, thanks for opening the first issue!

That's a great idea, and I actually have it on my TODO for the next phase of the project 😄. I'd have to do a bit more analysis, but off the top of my head, I'm pretty sure that most of the VS Code references in the core documentation logic are simply to show warning messages in VS Code when something goes wrong. So it shouldn't be too difficult to decouple these and make this idea work.

That said, time is fairly limited right now, and I wouldn't exactly say this is low hanging fruit. If you're interested in contributing, I'd be happy to collaborate, otherwise, I may wait until I have more free time, or until there's more demand for this (the project is still pretty new, with only ~100 or so downloads, so I don't expect demand to blossom any time too soon - positive reviews in the marketplace might help this though! 😉).

Anyway, thanks again for the issue, will definitely leave it open for now, pending further analysis.

no-stack-dub-sack avatar Dec 11 '19 17:12 no-stack-dub-sack

Great tool! We need the ability to execute this inside the CI preferably - just wanted to make sure you know there is an appreciation for your work and demand for this feature!

florianhoehn avatar Dec 30 '19 12:12 florianhoehn

@florianhoehn Awesome, thank you! And glad to know others see value in this as well. I'll try to look into it, but have been very busy lately. If you're familiar with TypeScript, feel free to look into the codebase and let me know if you have any suggestions on how to make this work.

The entry point to the program is here, and theoretically, if the command line could feed the necessary args into this method, it could work. But first, as @aranwe mentioned, there would need to be a way to skip calls to the vscode API when running via the command line.

These are mostly used to give warnings / errors to the user when executing within vscode, and aren't essential for the program to execute.

no-stack-dub-sack avatar Feb 03 '20 21:02 no-stack-dub-sack

I would totally love to see this implemented. Even though I cannot contribute (not a TypeScript developer), I would highly appreciate it. Preferably as a SFDX extension?

j-schreiber avatar Dec 27 '20 17:12 j-schreiber

Hi @jlietzau, thanks for the suggestion. I hope to eventually get to this, but without quite enough community support or demand, I haven't been able to find the time to prioritize this. If there's considerably more demand, this is something I could possibly look into more. Would definitely be open to contributions from others if anyone else sees this and would like to take it on!

no-stack-dub-sack avatar Jan 01 '21 19:01 no-stack-dub-sack

@no-stack-dub-sack : Thanks for this amazing plugin, it will add motivation to write better APEX code comments with annotations 👍 I have multiple customers which use CI/CD pipelines and it would be great to see HTML being generated on the fly and deployed as Github/Gitlab pages. Currently I advised developers to run HTML build phase in VS code and then commit HTML files to git. Downside of that is one more manual step which can easily forgotten to do. So CLI support would be great to automate this step

leojok-fluido avatar Aug 24 '21 07:08 leojok-fluido

@leojok-fluido I agree this would be great for ApexDox, but given the relatively low engagement on the project, I haven't been able to find the time to prioritize maintaining and adding new features. If you're interested in submitting a pull request, I'd be happy to review it and would almost certainly accept it as long as it worked 😎

no-stack-dub-sack avatar Oct 25 '21 01:10 no-stack-dub-sack

I really suspect it is already possible, it is just finding the correct syntax to invoke the code. Actually adding a command line interface to for 'sfdx' would be a really nice bonus... I can sort of do it by kicking off the same commands used for debugging, but that won't work in headless mode. If I get time to create another pull request, this will be what I'll work on next.

docbill avatar Oct 28 '22 18:10 docbill

Anyone looking for a Apex documentation tool with CLI capabilities should check out: https://github.com/cesarParra/apexdocs. I haven't vetted this extension myself but the README seems promising and it also generates markdown documentation rather than HTML so it can be viewed directly in github.

no-stack-dub-sack avatar Oct 31 '22 14:10 no-stack-dub-sack