/
vasiukoff
/
sg
Обзор
Документация
Войти
/
vasiukoff
/
sg
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
src/ViewModels/PruneRemote.cs
36 строк
856 B
leo
refactor: file-system watcher
01 сен 2025, 12:39
01 сен 2025, 12:39
cd80a55
Код
Авторство
О чём код?
using System.Threading.Tasks; namespace SourceGit.ViewModels { public class PruneRemote : Popup { public Models.Remote Remote { get; } public PruneRemote(Repository repo, Models.Remote remote) { _repo = repo; Remote = remote; } public override async Task<bool> Sure() { using var lockWatcher = _repo.LockWatcher(); ProgressDescription = "Run `prune` on remote ..."; var log = _repo.CreateLog($"Prune Remote '{Remote.Name}'"); Use(log); var succ = await new Commands.Remote(_repo.FullPath) .Use(log) .PruneAsync(Remote.Name); log.Complete(); return succ; } private readonly Repository _repo = null; } }