Skip to content

Commit 5df8b05

Browse files
committed
release 1.2.0
1 parent 413a92d commit 5df8b05

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "container-ps",
3-
"version": "1.1.0",
3+
"version": "1.2.0",
44
"main": "src/main.js",
55
"repository": "https://github.com/Toinane/docker-ps.git",
66
"author": "Toinane <[email protected]>",

src/List.js

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
const { clipboard, Menu } = require('electron')
1+
const { clipboard, dialog, Menu } = require('electron')
22

33
const Tray = require('./ContainerTray')
44
const Container = require('./Container')
@@ -92,6 +92,16 @@ class List {
9292
label: 'Delete Container',
9393
id: container.id,
9494
click: async event => {
95+
const response = await dialog.showMessageBox({
96+
type: 'warning',
97+
buttons: [ 'No', 'Yes' ],
98+
title: 'Do you really want to delete this container?',
99+
message: 'Do you really want to delete this container?',
100+
detail: 'This container will be deleted permanently and it will no longer be possible to recover it'
101+
})
102+
103+
if(!response) return
104+
95105
this.tray.setLoading()
96106
await Command.run('docker', ['stop', event.id])
97107
await Command.run('docker', ['rm', event.id])

0 commit comments

Comments
 (0)