Fix Windows and macOS
This commit is contained in:
12
src/main.rs
12
src/main.rs
@@ -110,7 +110,7 @@ fn run() -> Result<(), Error> {
|
|||||||
|
|
||||||
#[cfg(target_os = "linux")]
|
#[cfg(target_os = "linux")]
|
||||||
{
|
{
|
||||||
if !(opt.no_system) {
|
if !opt.no_system {
|
||||||
report.push_result(execute(
|
report.push_result(execute(
|
||||||
|terminal| linux::upgrade(&sudo, terminal, opt.dry_run),
|
|terminal| linux::upgrade(&sudo, terminal, opt.dry_run),
|
||||||
&mut terminal,
|
&mut terminal,
|
||||||
@@ -130,7 +130,7 @@ fn run() -> Result<(), Error> {
|
|||||||
&mut terminal,
|
&mut terminal,
|
||||||
));
|
));
|
||||||
|
|
||||||
if !(opt.no_emacs) {
|
if !opt.no_emacs {
|
||||||
git_repos.insert(base_dirs.home_dir().join(".emacs.d"));
|
git_repos.insert(base_dirs.home_dir().join(".emacs.d"));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -153,7 +153,7 @@ fn run() -> Result<(), Error> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if !(opt.no_git_repos) {
|
if !opt.no_git_repos {
|
||||||
if let Some(custom_git_repos) = config.git_repos() {
|
if let Some(custom_git_repos) = config.git_repos() {
|
||||||
for git_repo in custom_git_repos {
|
for git_repo in custom_git_repos {
|
||||||
git_repos.insert(git_repo);
|
git_repos.insert(git_repo);
|
||||||
@@ -192,7 +192,7 @@ fn run() -> Result<(), Error> {
|
|||||||
&mut terminal,
|
&mut terminal,
|
||||||
));
|
));
|
||||||
|
|
||||||
if !(opt.no_emacs) {
|
if !opt.no_emacs {
|
||||||
report.push_result(execute(
|
report.push_result(execute(
|
||||||
|terminal| generic::run_emacs(&base_dirs, terminal, opt.dry_run),
|
|terminal| generic::run_emacs(&base_dirs, terminal, opt.dry_run),
|
||||||
&mut terminal,
|
&mut terminal,
|
||||||
@@ -264,7 +264,7 @@ fn run() -> Result<(), Error> {
|
|||||||
|
|
||||||
#[cfg(target_os = "macos")]
|
#[cfg(target_os = "macos")]
|
||||||
{
|
{
|
||||||
if !(matches.is_present("no_system")) {
|
if !opt.no_system {
|
||||||
report.push_result(execute(
|
report.push_result(execute(
|
||||||
|terminal| macos::upgrade_macos(terminal, opt.dry_run),
|
|terminal| macos::upgrade_macos(terminal, opt.dry_run),
|
||||||
&mut terminal,
|
&mut terminal,
|
||||||
@@ -274,7 +274,7 @@ fn run() -> Result<(), Error> {
|
|||||||
|
|
||||||
#[cfg(windows)]
|
#[cfg(windows)]
|
||||||
{
|
{
|
||||||
if !(matches.is_present("no_system")) {
|
if !opt.no_system {
|
||||||
report.push_result(execute(
|
report.push_result(execute(
|
||||||
|terminal| powershell.windows_update(terminal, opt.dry_run),
|
|terminal| powershell.windows_update(terminal, opt.dry_run),
|
||||||
&mut terminal,
|
&mut terminal,
|
||||||
|
|||||||
Reference in New Issue
Block a user