2022-05-22 09:55:04 +02:00
|
|
|
#include <stdlib.h>
|
2022-05-23 20:45:35 +02:00
|
|
|
#include <limits.h>
|
2022-05-22 09:55:04 +02:00
|
|
|
|
2022-06-09 06:55:53 +02:00
|
|
|
#include "src/utils.h"
|
|
|
|
#include "src/preview.h"
|
2022-07-06 00:09:35 +02:00
|
|
|
#include "gen/previews.h"
|
2022-05-22 09:55:04 +02:00
|
|
|
|
|
|
|
/*
|
2022-06-09 06:55:53 +02:00
|
|
|
* This file is supposed to be included in src/ctpv.c
|
2022-05-22 09:55:04 +02:00
|
|
|
*/
|
|
|
|
|
2022-06-09 07:54:37 +02:00
|
|
|
#define PNAME(n) prev_scr_##n##_sh
|
2022-07-13 11:59:22 +02:00
|
|
|
#define PR(e, t, s, n, a) { #n, e, t, s, PNAME(n), 0, 0, a, LEN(PNAME(n)) }
|
2022-05-22 09:55:04 +02:00
|
|
|
|
2022-06-08 01:27:30 +02:00
|
|
|
Preview b_previews[] = {
|
2022-07-13 11:59:22 +02:00
|
|
|
PR(NULL, NULL, NULL, any, PREV_ATTR_NONE),
|
2022-06-10 13:46:38 +02:00
|
|
|
|
2022-07-13 11:59:22 +02:00
|
|
|
PR("md", NULL, NULL, mdcat, PREV_ATTR_NONE),
|
|
|
|
PR("torrent", NULL, NULL, torrent, PREV_ATTR_NONE),
|
|
|
|
PR("odt", NULL, NULL, odt, PREV_ATTR_NONE),
|
2022-06-10 13:46:38 +02:00
|
|
|
|
2022-07-13 11:59:22 +02:00
|
|
|
PR(NULL, "text", NULL, bat, PREV_ATTR_NONE),
|
|
|
|
PR(NULL, "text", NULL, highlight, PREV_ATTR_NONE),
|
|
|
|
PR(NULL, "text", NULL, source_highlight, PREV_ATTR_NONE),
|
|
|
|
PR(NULL, "text", NULL, cat, PREV_ATTR_NONE),
|
2022-06-10 13:46:38 +02:00
|
|
|
|
2022-07-13 11:59:22 +02:00
|
|
|
PR(NULL, "image", NULL, image, PREV_ATTR_NONE),
|
|
|
|
PR(NULL, "video", NULL, video, PREV_ATTR_NONE),
|
2022-06-10 13:46:38 +02:00
|
|
|
|
2022-07-13 11:59:22 +02:00
|
|
|
PR(NULL, "application", "pdf", pdf, PREV_ATTR_NONE),
|
|
|
|
PR(NULL, "application", "json", jq, PREV_ATTR_NONE),
|
2022-06-19 17:06:13 +02:00
|
|
|
|
2022-07-13 11:59:22 +02:00
|
|
|
PR(NULL, "inode", "directory", ls, PREV_ATTR_NONE),
|
|
|
|
PR(NULL, "inode", "symlink", symlink, PREV_ATTR_NONE),
|
2022-06-12 19:27:24 +02:00
|
|
|
|
2022-07-13 11:59:22 +02:00
|
|
|
PR(NULL, "text", "html", elinks, PREV_ATTR_NONE),
|
|
|
|
PR(NULL, "text", "html", lynx, PREV_ATTR_NONE),
|
|
|
|
PR(NULL, "text", "html", w3m, PREV_ATTR_NONE),
|
2022-06-12 19:27:24 +02:00
|
|
|
|
2022-07-13 11:59:22 +02:00
|
|
|
PR(NULL, "text", "x-diff", delta, PREV_ATTR_NONE),
|
|
|
|
PR(NULL, "text", "x-patch", delta, PREV_ATTR_NONE),
|
|
|
|
PR(NULL, "text", "x-diff", diff_so_fancy, PREV_ATTR_NONE),
|
|
|
|
PR(NULL, "text", "x-patch", diff_so_fancy, PREV_ATTR_NONE),
|
|
|
|
PR(NULL, "text", "x-diff", colordiff, PREV_ATTR_NONE),
|
|
|
|
PR(NULL, "text", "x-patch", colordiff, PREV_ATTR_NONE),
|
2022-06-10 13:46:38 +02:00
|
|
|
|
2022-07-27 15:00:16 +02:00
|
|
|
PR(NULL, "font", NULL, font, PREV_ATTR_NONE),
|
|
|
|
|
2022-07-13 11:59:22 +02:00
|
|
|
PR("tar.gz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tgz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tgz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tar.gz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tgz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tar.bz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tbz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tar.bz2", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tbz2", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tar.Z", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tZ", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tar.lzo", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tzo", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tar.lz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tlz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tar.xz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("txz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tar.7z", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("t7z", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("tar", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("zip", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("jar", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("war", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("rar", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("lha", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("lzh", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("7z", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("alz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("ace", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("a", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("arj", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("arc", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("rpm", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("deb", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("cab", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("gz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("bz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("bz2", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("Z", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("lzma", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("lzo", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("lz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("xz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("rz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("lrz", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("7z", NULL, NULL, atool, PREV_ATTR_NONE),
|
|
|
|
PR("cpio", NULL, NULL, atool, PREV_ATTR_NONE),
|
2022-06-17 19:50:17 +02:00
|
|
|
|
2022-07-13 11:59:22 +02:00
|
|
|
PR("gpg", NULL, NULL, gpg, PREV_ATTR_EXT_SHORT),
|
2022-05-22 09:55:04 +02:00
|
|
|
};
|
2022-05-28 19:33:18 +02:00
|
|
|
|
|
|
|
/* vim: set nowrap: */
|