Skip to content

Commit

Permalink
Minor tweaks & fixes
Browse files Browse the repository at this point in the history
Added the keep option & fixes some small issues
  • Loading branch information
iTzSharkSV committed Feb 24, 2022
1 parent a16b456 commit 5bcb561
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions Lib/Args.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,11 @@ ${gray('$')} ${green('hyper')} ${cyan('<commands>')} ${yellow('[options]')}
${bgCyan(` COMMANDS `)}\n
${cyan('help')} ${dim('Print help info')}
${cyan('init')} ${dim('Initialize a new project')}
${cyan('list')} ${dim('List available templates')}
${cyan('list')} ${dim('List available templates')}
${bgYellow(` OPTIONS `)}\n
${yellow('-k, --keep')} ${dim('Keep terminal output ')} ${gray('(off by Default)')}
${yellow('-y, --skip')} ${dim('Generate without prompt')}
${yellow('-y, --skip')} ${dim('Generate without prompt')}
${yellow('-i, --install')} ${dim('Install dependencies')}
${yellow('-v, --version')} ${dim('Print Cli version')} ${gray('(following semver)')}
`;
Expand All @@ -34,7 +34,7 @@ const Args = meow(helpTxt, {
flags: {
keep: {
type: 'boolean',
default: true,
default: false,
alias: 'k',
description: 'Keep terminal output'
},
Expand Down
8 changes: 4 additions & 4 deletions Lib/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,15 @@ import listTemplates from './Tasks/List';
import { UpdateNotifier } from 'update-notifier';

(async (): Promise<void> => {
const input: string[] = Args.input;
const flags = Args.flags;

Info({
title: 'Hyper',
tagLine: 'by @Shorky',
description: 'A Cli to bootstrap new projects',
version: '3.0',
clear: true
clear: flags.keep ? false : true
});

const pkg = {
Expand All @@ -25,9 +28,6 @@ import { UpdateNotifier } from 'update-notifier';
updateCheckInterval: 0
}).notify({ isGlobal: true });

const input: string[] = Args.input;
const flags = Args.flags;

// Cmds
input.includes('help') && Args.showHelp(0);
input.includes('list') && listTemplates();
Expand Down
4 changes: 2 additions & 2 deletions Templates/Static/Src/Ts/Scripts.ts
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
const msg = 'Hello World'
console.log(msg)
const msg = 'Hello World';
console.log(msg);

0 comments on commit 5bcb561

Please sign in to comment.