Show results before deleting them
This commit is contained in:
parent
64972a9ed3
commit
554f86ea4c
6
buku.1
6
buku.1
@ -344,14 +344,14 @@ If defined, will be used as the editor to edit bookmarks with option --write.
|
||||
.TP
|
||||
.BI https_proxy
|
||||
If defined, will be used to access http and https resources through the configured proxy. Supported format:
|
||||
|
||||
.br
|
||||
http[s]://[username:password@]proxyhost:proxyport/
|
||||
.TP
|
||||
.BI "GUI integration"
|
||||
.B buku
|
||||
can be integrated in a GUI environment with simple tweaks. Refer to:
|
||||
can be integrated in a GUI environment with simple tweaks. Please refer to:
|
||||
.br
|
||||
.I https://github.com/jarun/Buku#gui-integration
|
||||
.I https://github.com/jarun/Buku/wiki/System-integration
|
||||
.SH COLORS
|
||||
\fBbuku\fR allows you to customize the color scheme via a five-letter string, reminiscent of BSD \fBLSCOLORS\fR. The five letters represent the colors of
|
||||
.IP - 2
|
||||
|
12
buku.py
12
buku.py
@ -1365,6 +1365,12 @@ class BukuDb:
|
||||
return self.cleardb()
|
||||
|
||||
try:
|
||||
if self.chatty:
|
||||
if self.print_rec(0, low, high, True) is True:
|
||||
resp = input('Delete these bookmarks? (y/n): ')
|
||||
if resp != 'y':
|
||||
return False
|
||||
|
||||
query = 'DELETE from bookmarks where id BETWEEN ? AND ?'
|
||||
self.cur.execute(query, (low, high))
|
||||
print('Index %d-%d: %d deleted' % (low, high, self.cur.rowcount))
|
||||
@ -1386,6 +1392,12 @@ class BukuDb:
|
||||
return self.cleardb()
|
||||
else: # Remove a single entry
|
||||
try:
|
||||
if self.chatty:
|
||||
if self.print_rec(index) is True:
|
||||
resp = input('Delete this bookmark? (y/n): ')
|
||||
if resp != 'y':
|
||||
return False
|
||||
|
||||
query = 'DELETE FROM bookmarks WHERE id = ?'
|
||||
self.cur.execute(query, (index,))
|
||||
if self.cur.rowcount == 1:
|
||||
|
Loading…
x
Reference in New Issue
Block a user