mirror of
https://github.com/tio/tio.git
synced 2026-05-01 14:57:59 +02:00
Renamed "gotty" to "tio"
Renamed to "tio" because it is shorter and this new name also more precisely reflects what the program is - a simple TTY terminal I/O application. "tio" can be considered short for terminal I/O or TTY I/O or a combination of the two, whichever you prefer. Also, wanted to avoid naming conflicts with other projects.
This commit is contained in:
parent
f5f7ba7d8a
commit
9dd21af867
19 changed files with 79 additions and 99 deletions
|
|
@ -1,16 +1,16 @@
|
|||
bin_PROGRAMS = gotty
|
||||
gotty_SOURCES = tty.c \
|
||||
bin_PROGRAMS = tio
|
||||
tio_SOURCES = tty.c \
|
||||
options.c \
|
||||
time.c \
|
||||
main.c \
|
||||
log.c \
|
||||
include/gotty/tty.h \
|
||||
include/gotty/options.h \
|
||||
include/gotty/time.h \
|
||||
include/gotty/print.h \
|
||||
include/gotty/log.h
|
||||
include/tio/tty.h \
|
||||
include/tio/options.h \
|
||||
include/tio/time.h \
|
||||
include/tio/print.h \
|
||||
include/tio/log.h
|
||||
|
||||
if ENABLE_BASH_COMPLETION
|
||||
bashcompletiondir=@BASH_COMPLETION_DIR@
|
||||
dist_bashcompletion_DATA=bash-completion/gotty
|
||||
dist_bashcompletion_DATA=bash-completion/tio
|
||||
endif
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
#
|
||||
# Bash completion script for gotty.
|
||||
# Bash completion script for tio.
|
||||
#
|
||||
|
||||
_gotty()
|
||||
_tio()
|
||||
{
|
||||
local cur prev opts base
|
||||
COMPREPLY=()
|
||||
|
|
@ -100,5 +100,5 @@ _gotty()
|
|||
return 0
|
||||
}
|
||||
|
||||
# Bind completion to gotty command
|
||||
complete -o default -F _gotty gotty
|
||||
# Bind completion to tio command
|
||||
complete -o default -F _tio tio
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Go TTY - The Really Simple Terminal Application
|
||||
* tio - the simple TTY terminal I/O application
|
||||
*
|
||||
* Copyright (c) 2014-2016 Martin Lund
|
||||
*
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
* Go TTY - The Really Simple Terminal Application
|
||||
* tio - the simple TTY terminal I/O application
|
||||
*
|
||||
* Copyright (c) 2014 Martin Lund
|
||||
* Copyright (c) 2014-2016 Martin Lund
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
* Go TTY - The Really Simple Terminal Application
|
||||
* tio - the simple TTY terminal I/O application
|
||||
*
|
||||
* Copyright (c) 2014 Martin Lund
|
||||
* Copyright (c) 2014-2016 Martin Lund
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
* Go TTY - The Really Simple Terminal Application
|
||||
* tio - the simple TTY terminal I/O application
|
||||
*
|
||||
* Copyright (c) 2014 Martin Lund
|
||||
* Copyright (c) 2014-2016 Martin Lund
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
* Go TTY - The Really Simple Terminal Application
|
||||
* tio - the simple TTY terminal I/O application
|
||||
*
|
||||
* Copyright (c) 2014 Martin Lund
|
||||
* Copyright (c) 2014-2016 Martin Lund
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Go TTY - The Really Simple Terminal Application
|
||||
* tio - the simple TTY terminal I/O application
|
||||
*
|
||||
* Copyright (c) 2014-2016 Martin Lund
|
||||
*
|
||||
|
|
@ -23,8 +23,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <errno.h>
|
||||
#include "gotty/options.h"
|
||||
#include "gotty/print.h"
|
||||
#include "tio/options.h"
|
||||
#include "tio/print.h"
|
||||
|
||||
static FILE *fp;
|
||||
static bool error = false;
|
||||
|
|
|
|||
10
src/main.c
10
src/main.c
|
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
* Go TTY - The Really Simple Terminal Application
|
||||
* tio - the simple TTY terminal I/O application
|
||||
*
|
||||
* Copyright (c) 2014 Martin Lund
|
||||
* Copyright (c) 2014-2016 Martin Lund
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
|
@ -21,9 +21,9 @@
|
|||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include "gotty/options.h"
|
||||
#include "gotty/tty.h"
|
||||
#include "gotty/log.h"
|
||||
#include "tio/options.h"
|
||||
#include "tio/tty.h"
|
||||
#include "tio/log.h"
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
* Go TTY - The Really Simple Terminal Application
|
||||
* tio - the simple TTY terminal I/O application
|
||||
*
|
||||
* Copyright (c) 2014 Martin Lund
|
||||
* Copyright (c) 2014-2016 Martin Lund
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
|
@ -29,8 +29,8 @@
|
|||
#include <termios.h>
|
||||
#include <limits.h>
|
||||
#include "config.h"
|
||||
#include "gotty/options.h"
|
||||
#include "gotty/print.h"
|
||||
#include "tio/options.h"
|
||||
#include "tio/print.h"
|
||||
|
||||
struct option_t option =
|
||||
{
|
||||
|
|
@ -318,7 +318,7 @@ void parse_options(int argc, char *argv[])
|
|||
break;
|
||||
|
||||
case 'v':
|
||||
printf("Go TTY v%s\n", VERSION);
|
||||
printf("tio v%s\n", VERSION);
|
||||
printf("Copyright (c) 2014-2016 Martin Lund\n");
|
||||
printf("\n");
|
||||
printf("License GPLv2: GNU GPL version 2 or later <http://gnu.org/licenses/gpl-2.0.html>.\n");
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
* Go TTY - The Really Simple Terminal Application
|
||||
* tio - the simple TTY terminal I/O application
|
||||
*
|
||||
* Copyright (c) 2014 Martin Lund
|
||||
* Copyright (c) 2014-2016 Martin Lund
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
|
|
|||
18
src/tty.c
18
src/tty.c
|
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
* Go TTY - The Really Simple Terminal Application
|
||||
* tio - the simple TTY terminal I/O application
|
||||
*
|
||||
* Copyright (c) 2014 Martin Lund
|
||||
* Copyright (c) 2014-2016 Martin Lund
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
|
@ -31,11 +31,11 @@
|
|||
#include <termios.h>
|
||||
#include <stdbool.h>
|
||||
#include <errno.h>
|
||||
#include "gotty/tty.h"
|
||||
#include "gotty/print.h"
|
||||
#include "gotty/options.h"
|
||||
#include "gotty/time.h"
|
||||
#include "gotty/log.h"
|
||||
#include "tio/tty.h"
|
||||
#include "tio/print.h"
|
||||
#include "tio/options.h"
|
||||
#include "tio/time.h"
|
||||
#include "tio/log.h"
|
||||
|
||||
static int connected = false;
|
||||
struct termios new_stdout, old_stdout, old_tio;
|
||||
|
|
@ -120,7 +120,7 @@ void disconnect_tty(void)
|
|||
{
|
||||
if (tainted)
|
||||
putchar('\n');
|
||||
color_printf("[gotty %s] Disconnected", current_time());
|
||||
color_printf("[tio %s] Disconnected", current_time());
|
||||
close(fd);
|
||||
connected = false;
|
||||
}
|
||||
|
|
@ -156,7 +156,7 @@ int connect_tty(void)
|
|||
tcflush(fd, TCIOFLUSH);
|
||||
|
||||
/* Print connect status */
|
||||
color_printf("[gotty %s] Connected", current_time());
|
||||
color_printf("[tio %s] Connected", current_time());
|
||||
connected = true;
|
||||
tainted = false;
|
||||
bzero(&c_stdin[0], 3);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue