nano

nano with my custom patches
git clone git://bsandro.tech/nano
Log | Files | Refs | README | LICENSE

commit 11072ed5877eb82af4cf6d5651ea7fa25a7816a9
parent 67915f5daec8fa8f6258e639ebf500f66552542e
Author: Benno Schulenberg <bensberg@telfort.nl>
Date:   Sun,  6 Aug 2017 13:32:44 +0200

tweaks: sort the includes, so it's a little easier to see what is there

Diffstat:
Msrc/browser.c | 2+-
Msrc/chars.c | 2+-
Msrc/color.c | 5++---
Msrc/files.c | 8++++----
Msrc/help.c | 2+-
Msrc/nano.c | 16++++++++--------
Msrc/rcfile.c | 4++--
Msrc/text.c | 6+++---
Msrc/utils.c | 6+++---
Msrc/winio.c | 3+--
10 files changed, 26 insertions(+), 28 deletions(-)

diff --git a/src/browser.c b/src/browser.c @@ -21,10 +21,10 @@ #include "proto.h" +#include <errno.h> #include <stdint.h> #include <string.h> #include <unistd.h> -#include <errno.h> #ifdef ENABLE_BROWSER diff --git a/src/chars.c b/src/chars.c @@ -21,8 +21,8 @@ #include "proto.h" -#include <string.h> #include <ctype.h> +#include <string.h> #ifdef ENABLE_UTF8 #include <wchar.h> diff --git a/src/color.c b/src/color.c @@ -21,13 +21,12 @@ #include "proto.h" -#include <string.h> #include <errno.h> -#include <unistd.h> - #ifdef HAVE_MAGIC_H #include <magic.h> #endif +#include <string.h> +#include <unistd.h> #ifndef DISABLE_COLOR diff --git a/src/files.c b/src/files.c @@ -21,14 +21,14 @@ #include "proto.h" -#include <string.h> -#include <unistd.h> -#include <fcntl.h> #include <errno.h> +#include <fcntl.h> +#include <libgen.h> #ifdef HAVE_PWD_H #include <pwd.h> #endif -#include <libgen.h> +#include <string.h> +#include <unistd.h> #define LOCKBUFSIZE 8192 diff --git a/src/help.c b/src/help.c @@ -22,8 +22,8 @@ #include "proto.h" -#include <string.h> #include <errno.h> +#include <string.h> #ifdef ENABLE_HELP diff --git a/src/nano.c b/src/nano.c @@ -22,22 +22,22 @@ #include "proto.h" #include "revision.h" -#include <unistd.h> -#include <string.h> -#include <fcntl.h> -#include <errno.h> #include <ctype.h> +#include <errno.h> +#include <fcntl.h> +#include <getopt.h> +#ifndef NANO_TINY +#include <sys/ioctl.h> +#endif #ifdef ENABLE_UTF8 #include <langinfo.h> #endif #include <locale.h> +#include <string.h> #ifdef HAVE_TERMIOS_H #include <termios.h> #endif -#include <getopt.h> -#ifndef NANO_TINY -#include <sys/ioctl.h> -#endif +#include <unistd.h> #ifdef ENABLE_MOUSE static int oldinterval = -1; diff --git a/src/rcfile.c b/src/rcfile.c @@ -22,11 +22,11 @@ #include "proto.h" +#include <ctype.h> +#include <errno.h> #include <glob.h> #include <string.h> -#include <errno.h> #include <unistd.h> -#include <ctype.h> #ifdef ENABLE_NANORC diff --git a/src/text.c b/src/text.c @@ -24,11 +24,11 @@ #include "proto.h" -#include <unistd.h> -#include <string.h> +#include <errno.h> #include <fcntl.h> +#include <string.h> +#include <unistd.h> #include <sys/wait.h> -#include <errno.h> #ifndef NANO_TINY static pid_t pid = -1; diff --git a/src/utils.c b/src/utils.c @@ -21,12 +21,12 @@ #include "proto.h" -#include <string.h> -#include <unistd.h> +#include <errno.h> #ifdef HAVE_PWD_H #include <pwd.h> #endif -#include <errno.h> +#include <string.h> +#include <unistd.h> /* Return the user's home directory. We use $HOME, and if that fails, * we fall back on the home directory of the effective user ID. */ diff --git a/src/winio.c b/src/winio.c @@ -22,12 +22,11 @@ #include "proto.h" #include "revision.h" +#include <ctype.h> #ifdef __linux__ #include <sys/ioctl.h> #endif - #include <string.h> -#include <ctype.h> #ifdef REVISION #define BRANDING REVISION