View | Details | Raw Unified | Return to bug 237839 | Differences between
and this patch

Collapse All | Expand All

(-)Makefile (-7 / +7 lines)
Lines 1-9 Link Here
1
# $FreeBSD$
1
# $FreeBSD$
2
2
3
PORTNAME=		sc-im
3
PORTNAME=		sc-im
4
PORTVERSION=		0.7.0
4
DISTVERSIONPREFIX=	g
5
DISTVERSIONPREFIX=	v
5
DISTVERSION=		20190222
6
PORTREVISION=		1
7
CATEGORIES=		math
6
CATEGORIES=		math
8
7
9
MAINTAINER=	bapt@FreeBSD.org
8
MAINTAINER=	bapt@FreeBSD.org
Lines 12-23 Link Here
12
LICENSE=	BSD4CLAUSE
11
LICENSE=	BSD4CLAUSE
13
12
14
LIB_DEPENDS=	libxlsreader.so:math/libxls \
13
LIB_DEPENDS=	libxlsreader.so:math/libxls \
15
		libzip.so:archivers/libzip \
14
		libxlsxwriter.so:math/libxlsxwriter \
16
		libxlsxwriter.so:math/libxlsxwriter
15
		libzip.so:archivers/libzip
17
16
18
USES=		gmake pkgconfig lua:51 ncurses
17
USES=		gmake gnome lua:51 ncurses pkgconfig
19
USE_GITHUB=	yes
18
USE_GITHUB=	yes
20
GH_ACCOUNT=	andmarti1424
19
GH_ACCOUNT=	andmarti1424
20
GH_TAGNAME=	9beb5c0
21
USE_GNOME=	libxml2
21
USE_GNOME=	libxml2
22
22
23
WRKSRC_SUBDIR=	src
23
WRKSRC_SUBDIR=	src
Lines 27-32 Link Here
27
MAKE_ARGS+=	CC="${CC}" prefix="${PREFIX}" MANDIR="${MANPREFIX}/man/man1"
27
MAKE_ARGS+=	CC="${CC}" prefix="${PREFIX}" MANDIR="${MANPREFIX}/man/man1"
28
28
29
post-install:
29
post-install:
30
	${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/scim
30
	${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/sc-im
31
31
32
.include <bsd.port.mk>
32
.include <bsd.port.mk>
(-)distinfo (-3 / +3 lines)
Lines 1-3 Link Here
1
TIMESTAMP = 1513334880
1
TIMESTAMP = 1557592626
2
SHA256 (andmarti1424-sc-im-v0.7.0_GH0.tar.gz) = 87225918cb6f52bbc068ee6b12eaf176c7c55ba9739b29ca08cb9b6699141cad
2
SHA256 (andmarti1424-sc-im-g20190222-9beb5c0_GH0.tar.gz) = 755b201bebdb59a4e6d516ad094b886a34efc27d7cd84f88c6011fa05622bc05
3
SIZE (andmarti1424-sc-im-v0.7.0_GH0.tar.gz) = 1109887
3
SIZE (andmarti1424-sc-im-g20190222-9beb5c0_GH0.tar.gz) = 1114358
(-)files/patch-cmds__command.c (-2 / +2 lines)
Lines 1-6 Link Here
1
--- cmds_command.c.orig	2018-08-03 06:04:39 UTC
1
--- cmds_command.c.orig	2019-02-22 18:41:46 UTC
2
+++ cmds_command.c
2
+++ cmds_command.c
3
@@ -826,7 +826,7 @@ void do_commandmode(struct block * sb) {
3
@@ -853,7 +853,7 @@ void do_commandmode(struct block * sb) {
4
             exec_cmd(line);
4
             exec_cmd(line);
5
 
5
 
6
         } else if ( inputline[0] == L'w' ) {
6
         } else if ( inputline[0] == L'w' ) {
(-)files/patch-doc (-2 / +2 lines)
Lines 1-6 Link Here
1
--- doc.orig	2018-08-03 06:09:42 UTC
1
--- doc.orig	2019-02-22 18:41:46 UTC
2
+++ doc
2
+++ doc
3
@@ -328,6 +328,8 @@ Commands for handling cell content:
3
@@ -330,6 +330,8 @@ Commands for handling cell content:
4
      :w {file}   Save the current spreadsheet as {file}.
4
      :w {file}   Save the current spreadsheet as {file}.
5
      :w! {file}  Save the current spreadsheet as {file}, forcing an overwrite
5
      :w! {file}  Save the current spreadsheet as {file}, forcing an overwrite
6
                  if {file} already exists.
6
                  if {file} already exists.
(-)files/patch-file.c (-12 / +42 lines)
Lines 1-16 Link Here
1
--- file.c.orig	2017-12-13 17:48:59 UTC
1
--- file.c.orig	2019-05-11 16:23:57 UTC
2
+++ file.c
2
+++ file.c
3
@@ -202,7 +202,12 @@ int savefile() {
3
@@ -189,21 +189,23 @@ int modcheck() {
4
     del_range_chars(name, 0, 1 + force_rewrite);
4
 
5
 int savefile() {
6
     int force_rewrite = 0;
7
+    int shall_quit = 0;
8
     char name[BUFFERSIZE];
9
     #ifndef NO_WORDEXP
10
     size_t len;
11
     wordexp_t p;
12
     #endif
13
 
14
-    if (! curfile[0] && wcslen(inputline) < 3) { // casos ":w" ":w!" ":x" ":x!"
15
+    if (! curfile[0] && wcslen(inputline) < 3) { // casos ":w" ":w!" ":wq" ":x" ":x!"
16
         sc_error("There is no filename");
17
         return -1;
18
     }
19
 
20
     if (inputline[1] == L'!') force_rewrite = 1;
21
+    if (inputline[1] == L'q') shall_quit = 1;
22
 
23
     wcstombs(name, inputline, BUFFERSIZE);
24
-    del_range_chars(name, 0, 1 + force_rewrite);
25
+    del_range_chars(name, 0, 1 + force_rewrite + shall_quit);
26
 
27
     #ifndef NO_WORDEXP
5
     wordexp(name, &p, 0);
28
     wordexp(name, &p, 0);
29
@@ -221,7 +223,7 @@ int savefile() {
30
     #endif
6
 
31
 
7
-    if (! force_rewrite && p.we_wordv[0] && file_exists(p.we_wordv[0])) {
32
     if (! force_rewrite && file_exists(name)) {
8
+    if (wcslen(inputline) > 2 && (!p.we_wordv || !p.we_wordv[0])) {
33
-        sc_error("File already exists. Use \"!\" to force rewrite.");
9
+       sc_error("Trailing space(s)");
34
+        sc_error("File already exists. Use \"w!\" to force rewrite.");
10
+       return -1;
11
+    }
12
+
13
+    if (! force_rewrite && p.we_wordv && p.we_wordv[0] && file_exists(p.we_wordv[0])) {
14
         sc_error("File already exists. Use \"!\" to force rewrite.");
15
         wordfree(&p);
16
         return -1;
35
         return -1;
36
     }
37
 
38
@@ -235,7 +237,7 @@ int savefile() {
39
     // if it exists and no '!' is set, return.
40
     if (!strlen(curfile) && backup_exists(name)) {
41
         if (!force_rewrite) {
42
-            sc_error("Backup file of %s exists. Use \"!\" to force the write process.", name);
43
+            sc_error("Backup file of %s exists. Use \"w!\" to force the write process.", name);
44
             return -1;
45
         } else remove_backup(name);
46
     }
(-)pkg-plist (-7 / +7 lines)
Lines 1-7 Link Here
1
bin/scim
1
bin/sc-im
2
man/man1/scim.1.gz
2
man/man1/sc-im.1.gz
3
share/scim/plot_bar
3
share/sc-im/plot_bar
4
share/scim/plot_line
4
share/sc-im/plot_line
5
share/scim/plot_pie
5
share/sc-im/plot_pie
6
share/scim/plot_scatter
6
share/sc-im/plot_scatter
7
share/scim/scim_help
7
share/sc-im/sc-im_help

Return to bug 237839