downloading and extracting

This commit is contained in:
SpikeHD
2022-07-24 18:14:18 -07:00
parent 975b04fd0e
commit 36c2302f1b
13 changed files with 143 additions and 28 deletions

View File

@@ -1,10 +1,11 @@
import { invoke } from '@tauri-apps/api'
import { listen } from '@tauri-apps/api/event'
export function unzip(file: string, dest: string, onFinish?: () => void) {
export function unzip(file: string, dest: string, topLevelStrip?: boolean, onFinish?: () => void) {
invoke('unzip', {
zipfile: file,
destpath: dest,
topLevelStrip,
})
listen('extract_end', ({ payload }) => {