src/winio.c (display_string, statusbar): Allow toggling the display
of whitespace also when support for nanorc files was not built in,
because the default values are quite usable.
+ * src/files.c (read_file), src/rcfile.c, src/nano.c (main, usage):
+ Fix compilation with --enable-tiny; file formats are not available
+ then, so option --unix has no place; also add its description.
2015-08-08 Benno Schulenberg <bensberg@justemail.net>
* src/winio.c (display_string): For some reason the reallocation done
"Read %lu lines (Warning: No write permission)",
(unsigned long)num_lines), (unsigned long)num_lines);
+#ifndef NANO_TINY
if (ISSET(MAKE_IT_UNIX))
openfile->fmt = NIX_FILE;
+#endif
}
/* Open the file (and decide if it exists). If newfie is TRUE, display
N_("Enable alternate speller"));
#endif
print_opt("-t", "--tempfile", N_("Auto save on exit, don't prompt"));
+#ifndef NANO_TINY
+ print_opt("-u", "--unix", N_("Save a file by default in Unix format"));
+#endif
print_opt("-v", "--view", N_("View mode (read-only)"));
#ifndef DISABLE_WRAPPING
print_opt("-w", "--nowrap", N_("Don't hard-wrap long lines"));
{"speller", 1, NULL, 's'},
#endif
{"tempfile", 0, NULL, 't'},
- {"unix", 0, NULL, 'u'},
{"view", 0, NULL, 'v'},
#ifndef DISABLE_WRAPPING
{"nowrap", 0, NULL, 'w'},
{"wordbounds", 0, NULL, 'W'},
{"autoindent", 0, NULL, 'i'},
{"cut", 0, NULL, 'k'},
+ {"unix", 0, NULL, 'u'},
{"softwrap", 0, NULL, '$'},
#endif
{NULL, 0, NULL, 0}
case 't':
SET(TEMP_FILE);
break;
+#ifndef NANO_TINY
case 'u':
SET(MAKE_IT_UNIX);
break;
+#endif
case 'v':
SET(VIEW_MODE);
break;
{"suspend", SUSPEND},
{"tabsize", 0},
{"tempfile", TEMP_FILE},
- {"unix", MAKE_IT_UNIX},
{"view", VIEW_MODE},
#ifndef NANO_TINY
{"allow_insecure_backup", INSECURE_BACKUP},
{"smooth", SMOOTH_SCROLL},
{"softwrap", SOFTWRAP},
{"tabstospaces", TABS_TO_SPACES},
+ {"unix", MAKE_IT_UNIX},
{"whitespace", 0},
{"wordbounds", WORD_BOUNDS},
#endif