Skip to content

Commit

Permalink
Fixed cleanup path and cleanup text (#207)
Browse files Browse the repository at this point in the history
* Changed "Quick actions" to "snippets"

* Changed Community Actions to Snippets

* Version bump

* Version bump

* Changed snippet to code snippet

* Upgraded dependencies

* Fixed windows recreating distro folders

* Fixed cleanup path

* Fixed cleanup text
  • Loading branch information
bostrot authored Aug 13, 2023
1 parent 7aed7dc commit 033042f
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions lib/api/wsl.dart
Original file line number Diff line number Diff line change
Expand Up @@ -548,14 +548,14 @@ class WSLApi {

/// Clean up WSL distros. Exporting, deleting, and importing.
Future<String> cleanup(String distribution) async {
var file = getInstancePath(distribution).file('export.tar.gz');
var instancePath = getInstancePath(distribution);
var file = instancePath.file('export.tar.gz');

// Export, remove, and import
await export(distribution, file);
await remove(distribution);
var res = await import(distribution, '', file);

return res;
return await import(distribution, instancePath.path, file);
}

/// Returns list of WSL distros
Expand Down
2 changes: 1 addition & 1 deletion lib/i18n/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@
"language-text": "Language",
"languagechange-text": "Language change will take effect after restart.",
"notemplates-text": "No templates found",
"cleanuptitle-text": "Clean up WSL instance ($s0)",
"cleanuptitle-text": "Clean up WSL instance (%s0)",
"cleanupbody-text": "Do you really want to clean up the distribution? This will export and re-import the distribution. This may take some time.",
"continue-text": "Continue",
"cleanup-text": "Cleanup",
Expand Down
2 changes: 1 addition & 1 deletion lib/i18n/pt.json
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@
"language-text": "Idioma",
"languagechange-text": "A alteração de idioma terá efeito após o reinício.",
"notemplates-text": "Nenhum modelo encontrado",
"cleanuptitle-text": "Limpar instância WSL ($s0)",
"cleanuptitle-text": "Limpar instância WSL (%s0)",
"cleanupbody-text": "Você realmente quer limpar a distribuição? Isso exportará e importará a distribuição novamente. Isso pode levar algum tempo.",
"continue-text": "Continuar",
"cleanuptext-text": "Limpar",
Expand Down
2 changes: 1 addition & 1 deletion lib/i18n/zh_tw.json
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@
"language-text": "語言",
"languagechange-text": "語言變更將在重新啟動後生效。",
"notemplates-text": "沒有找到範本",
"cleanuptitle-text": "清理 WSL 安裝實體 ($s0)",
"cleanuptitle-text": "清理 WSL 安裝實體 (%s0)",
"cleanupbody-text": "您確定要清理發行版本嗎?這將匯出並重新匯入發行版本。這可能需要一些時間。",
"continue-text": "繼續",
"cleanup-text": "清理",
Expand Down
6 changes: 3 additions & 3 deletions lib/nav/init.dart
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,9 @@ initRoot(statusMsg) async {
// if (kDebugMode) {
// prefs.remove('version');
// }
if (kDebugMode) {
prefs.setString('version', '1.8.0');
}
// if (kDebugMode) {
// prefs.setString('version', '1.8.0');
// }

// Check updates
App app = App();
Expand Down

0 comments on commit 033042f

Please sign in to comment.