diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3919f69..50da72f 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -32,18 +32,9 @@ jobs: toolchain: stable override: true - - name: Install musl-gcc - run: | - sudo apt-get update - sudo apt-get install -y musl-tools - - name: Install target run: rustup target add ${{ matrix.target }} - - name: Install dependencies for tinyfiledialogs - run: | - sudo apt-get install -y libx11-dev libglib2.0-dev - - name: Check Rust target installation run: rustup target list --installed @@ -52,17 +43,7 @@ jobs: echo "Compiling for target: ${{ matrix.target }}" cargo build --release --target ${{ matrix.target }} - - name: Debugging - Check compiled binary - run: | - echo "Listing the compiled files:" - ls -lh target/${{ matrix.target }}/release/ - - - name: Run the app (for testing purposes) - run: | - echo "Running the compiled app for testing" - target/${{ matrix.target }}/release/calcifer --help || true - - - name: Create tarball + - name: Create tarball run: | release_tag=${{ github.event.release.tag_name }} tar -czvf calcifer_v${release_tag}.tar.gz -C target/${{ matrix.target }}/release calcifer diff --git a/src/core/app.rs b/src/core/app.rs index e4b7f55..5c779f0 100644 --- a/src/core/app.rs +++ b/src/core/app.rs @@ -51,16 +51,16 @@ impl Calcifer { } else { self.tabs[self.selected_tab].path.to_string_lossy() }; - println!("app : open dialog at {}", save_path); - if let Some(path_string) = tinyfiledialogs::save_file_dialog("Save as", &save_path) - { - let path = PathBuf::from(path_string); - if let Err(err) = fs::write(&path, &self.tabs[self.selected_tab].code) { - eprintln!("Error writing file: {}", err); - return None; - } - return Some(path); - } + println!("app : tried to open dialog at {}", save_path); +// if let Some(path_string) = tinyfiledialogs::save_file_dialog("Save as", &save_path) +// { +// let path = PathBuf::from(path_string); +// if let Err(err) = fs::write(&path, &self.tabs[self.selected_tab].code) { +// eprintln!("Error writing file: {}", err); +// return None; +// } +// return Some(path); +// } None } diff --git a/src/core/ui.rs b/src/core/ui.rs index 06667e3..0626301 100644 --- a/src/core/ui.rs +++ b/src/core/ui.rs @@ -22,10 +22,11 @@ impl Calcifer { .show(ctx, |ui| { ui.vertical(|ui| { if ui.add(egui::Button::new("📁")).clicked() { - if let Some(path_string) = tinyfiledialogs::open_file_dialog("Open File", &self.home.to_string_lossy(), None) - { - self.open_file(Some(&Path::new(&path_string))); - } + println!("ui : open file, wip"); +// if let Some(path_string) = tinyfiledialogs::open_file_dialog("Open File", &self.home.to_string_lossy(), None) +// { +// self.open_file(Some(&Path::new(&path_string))); +// } } ui.separator(); self.tree_visible = self.toggle(ui, self.tree_visible, "📦"); @@ -55,7 +56,7 @@ impl Calcifer { } egui::SidePanel::left("file_tree_panel").show(ctx, |ui| { ui.horizontal(|ui| { - ui.label(format!("Bookshelf ({} files) ", self.n_file_displayed)); + ui.label(format!("Bookshelf ({} files) ", self.n_file_displayed)); if ui.button("↺").clicked() { self.file_tree = None; }