Export default value providers
This commit is contained in:
@@ -116,7 +116,7 @@ async function getValues(
|
||||
(parent.definition?.key && defaultValueProviders[parent.definition.key]);
|
||||
|
||||
if (valueProvider) {
|
||||
const values = valueProvider();
|
||||
const values = valueProvider(workflowContext);
|
||||
return filterAndSortCompletionOptions(values, existingValues);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import {Value, WorkflowContext} from "./config";
|
||||
import {getJobNames} from "./needs";
|
||||
|
||||
const defaultValueProviders: {[key: string]: (workflowContext: WorkflowContext) => Value[]} = {
|
||||
export const defaultValueProviders: {[key: string]: (workflowContext: WorkflowContext) => Value[]} = {
|
||||
needs: (workflowContext: WorkflowContext) => getJobNames(workflowContext.template),
|
||||
"runs-on": () =>
|
||||
stringsToValues([
|
||||
|
||||
Reference in New Issue
Block a user