Skip to content

Commit

Permalink
Merge branch 'master' into docker
Browse files Browse the repository at this point in the history
  • Loading branch information
rolandtshen authored Mar 19, 2021
2 parents 3547576 + 0c44b74 commit 7a2e511
Show file tree
Hide file tree
Showing 8 changed files with 1,336 additions and 117 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@ building_scripts/
node_modules
build
npm-debug.log
.env
.env
.idea/
2 changes: 1 addition & 1 deletion schemas/Arg.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const Arg = Joi.object({
insertValue: Joi.string().allow(''),
description: Joi.string().optional().allow(''),
icon: Joi.string(),
suggestions: Joi.array().items(Suggestion),
suggestions: Joi.alternatives().try(Joi.array().items(Joi.string()), Joi.array().items(Suggestion)),
template: Joi.alternatives().try(Joi.string().valid("filepaths", "folders"), Joi.array().items(Joi.string().valid("filepaths", "folders"))),
generators: Joi.alternatives().try(Generator, Joi.array().items(Generator)),
generator: Joi.alternatives().try(Generator),
Expand Down
1 change: 1 addition & 0 deletions specs/brew.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ var completionSpec = {
{ name: "update", description: "Fetch the newest version of Homebrew and all formulae" },
{ name: "upgrade", description: "Upgrade outdated casks and outdated" },
{ name: "search", description: "Perform a substring search of cask tokens and formula names" },
{ name: "config", description: "Show Homebrew and system configuration info" },
{
name: "install",
description: "Install <formula>",
Expand Down
27 changes: 13 additions & 14 deletions specs/docker.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,26 +14,26 @@ var postProcessDockerPs = (out) => {
}

var generators = {
runningDockerContainers: {
script: `docker ps --format '{{ json . }}'`,
postProcess: postProcessDockerPs
},
allDockerContainers: {
script: `docker ps -a --format '{{ json . }}'`,
postProcess: postProcessDockerPs
},
runningDockerContainers: {
script: `docker ps --format '{{ json . }}'`,
postProcess: postProcessDockerPs
},
allDockerContainers: {
script: `docker ps -a --format '{{ json . }}'`,
postProcess: postProcessDockerPs
},
pausedDockerContainers: {
script: `docker ps --filter status=paused --format '{{ json . }}'`,
postProcess: postProcessDockerPs
},
allLocalImages: {
script: `docker image ls --format '{{ json . }}'`,
postProcess: function (out) {
let allLines = out.split('\n').map(JSON.parse);
return allLines.map(i => ({
name: `${i.Repository}`,
}));
}
let allLines = out.split('\n').map(JSON.parse);
return allLines.map(i => ({
name: `${i.Repository}`,
}));
}
}
};

Expand Down Expand Up @@ -2473,5 +2473,4 @@ var completionSpec = {
subcommands: []
}
]

}
Loading

0 comments on commit 7a2e511

Please sign in to comment.