docs(core): fixes for custom tasks runner docs (#29785)

Tweaks to the new custom tasks runner docs
This commit is contained in:
Isaac Mann 2025-01-28 12:31:15 -05:00 committed by GitHub
parent ca89f14eb3
commit 87f1dda046
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 11 additions and 11 deletions

View File

@ -27,7 +27,7 @@ export default async function customTasksRunner(tasks, options, context) {
throw new Error('Env is not set up correctly');
}
const allTaskResults = {};
const lifeCyle = {
const lifeCycle = {
endTasks(taskResults) {
taskResults.forEach((tr) => {
allTaskResults[tr.task.id] = tr;
@ -36,7 +36,7 @@ export default async function customTasksRunner(tasks, options, context) {
};
const ret = await defaultTasksRunner(
tasks,
{ ...options, lifeCyle },
{ ...options, lifeCycle },
context
);
if (options.reportAnalytics) {
@ -157,7 +157,7 @@ You can replace it with two plugins:
}
```
Simple add a condition to your hooks as follows:
Simply add a condition to your hooks as follows:
```typescript
export async function preTasksExecution() {
@ -169,7 +169,7 @@ export async function postTasksExecution(options, tasksResults) {
}
```
You can then choose which hooks ot use by setting the RUNNER env variable.
You can then choose which hooks to use by setting the RUNNER env variable.
### Passing Options

View File

@ -8,7 +8,7 @@ All licenses are perpetual, so you can use the latest version of Nx available to
[Get Your Free License Immediately](https://cloud.nx.app/powerpack/request/free)
We understand that some organizations may not neatly fit this definition (e.g., a larger organization with a small number of engineers using an Nx workspace). We'd like to unblock you. [Please reach out.](powerpack-support@nrwl.io)
We understand that some organizations may not neatly fit this definition (e.g., a larger organization with a small number of engineers using an Nx workspace). We'd like to unblock you. [Please reach out.](mailto:powerpack-support@nrwl.io)
## OSS License
@ -20,8 +20,8 @@ You can get a free, 30-day license immediately if you want to try Nx Powerpack.
[Get Your Trial License Immediately](https://cloud.nx.app/powerpack/request/trial)
If you're having trouble, [reach out for help.](powerpack-support@nrwl.io)
If you're having trouble, [reach out for help.](mailto:powerpack-support@nrwl.io)
## Extended Trial Periods
Nx Powerpack does not make any requests to external APIs, and activating Powerpack can be completed in just a few minutes. However, we understand that in many large organizations approval processes can take a long time. We're here to help you. Need a trial extension or help with your business case? [Reach out and we'll help.](powerpack-support@nrwl.io)
Nx Powerpack does not make any requests to external APIs, and activating Powerpack can be completed in just a few minutes. However, we understand that in many large organizations approval processes can take a long time. We're here to help you. Need a trial extension or help with your business case? [Reach out and we'll help.](mailto:powerpack-support@nrwl.io)

View File

@ -17,15 +17,15 @@ export function Faq(): ReactElement {
{
question: 'Does Nx Powerpack activation require network access?',
answer:
'If you enable Nx Powerpack without Nx Cloud, no networks will be created and no data will be collected.',
'If you enable Nx Powerpack without Nx Cloud, no network requests will be created and no data will be collected.',
},
{
question: 'Can I get Nx Powerpack license for free?',
question: 'Can I get an Nx Powerpack license for free?',
answer:
'Open source projects can get Powerpack for free, and small teams can get a remote cache only license for free. All licenses are perpetual and licenses can be updated as long as the organization still qualifies.',
},
{
question: 'How we define a small team?',
question: 'How do we define a small team?',
answer:
'We value small teams using Nx. That is why we provide a free, perpetual, remote cache only license to any company with fewer than 30 engineers using Nx. If you have a special case, reach out and we will help. Read more here: https://nx.dev/nx-enterprise/powerpack/free-licenses-and-trials',
},
@ -38,7 +38,7 @@ export function Faq(): ReactElement {
question:
'Only interested in Nx Powerpack because of Custom Tasks Runner deprecation',
answer:
'We created a transition path from using Custom Tasks Runners to using the new plugins api hooks (beforeTasksExecution and aftertTasksExectution) and Nx Powerpack. Read more here: https://nx.dev/deprecated/custom-tasks-runner',
'We created a transition path from using Custom Tasks Runners to using the new plugins api hooks (preTasksExecution and postTasksExectution) and Nx Powerpack. Read more here: https://nx.dev/deprecated/custom-tasks-runner',
},
{
question: 'Is Nx Powerpack license perpetual?',