diff options
| author | Curtis McEnroe | 2018-08-18 18:31:51 -0400 | 
|---|---|---|
| committer | Curtis McEnroe | 2018-08-18 18:31:51 -0400 | 
| commit | e29f67dde5c1ec8a76259b3f062a49deab028054 (patch) | |
| tree | 02e1f6680d38e04a2c1f54933fa009127688b65a | |
| parent | 6ec3c3011e4328444051c58f01b57c8175f72e4b (diff) | |
Alias /n to /view n where n is a number
| -rw-r--r-- | input.c | 9 | 
1 files changed, 8 insertions, 1 deletions
@@ -178,7 +178,14 @@ void input(struct Tag tag, char *input) {  		COMMANDS[i].handler(tag, input);  		return;  	} -	uiFmt(TAG_STATUS, UI_WARM, "%s isn't a recognized command", command); + +	char *trail; +	strtol(&command[1], &trail, 0); +	if (!trail[0]) { +		inputView(tag, &command[1]); +	} else { +		uiFmt(TAG_STATUS, UI_WARM, "%s isn't a recognized command", command); +	}  }  void inputTab(void) {  | 
