Skip to content

Commit

Permalink
Merge pull request #34 from ckaznable/windows
Browse files Browse the repository at this point in the history
fix: build failed on windows
  • Loading branch information
ckaznable committed Jan 8, 2024
2 parents 472475c + dcbcc91 commit acdedf3
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,19 +28,19 @@ jobs:
- name: cargo fmt -- --check
run: cargo fmt --all -- --check


test:
name: Test
needs: [style]
runs-on: ubuntu-latest

strategy:
matrix:
build: [stable, beta, nightly]
os: [ubuntu-latest, windows-latest, macos-latest]
include:
- build: nightly
benches: true

runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v3
Expand Down Expand Up @@ -168,4 +168,4 @@ jobs:
- name: Publish
uses: softprops/action-gh-release@v1
with:
files: 'poketex*'
files: 'poketex*'
3 changes: 3 additions & 0 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ use std::{
path::{Path, PathBuf},
rc::Rc,
};

#[cfg(unix)]
use xdg::BaseDirectories;

use clap::Parser;
Expand Down Expand Up @@ -128,6 +130,7 @@ fn get_assets_dir_path() -> Result<PathBuf> {
};

// xdg data home
#[cfg(unix)]
if let Ok(xdg_dir) = BaseDirectories::new() {
let data_home = xdg_dir.get_data_home().join("poketex");
let assets_dir = data_home.join(assets_path);
Expand Down

0 comments on commit acdedf3

Please sign in to comment.