Skip to content

Commit

Permalink
fix: windows path checking (#864)
Browse files Browse the repository at this point in the history
  • Loading branch information
vitoUwu authored Oct 31, 2024
1 parent c957a1c commit 8bde8b5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
4 changes: 2 additions & 2 deletions dev/deno.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import {
initLoader,
parsePath,
} from "@deco/deco/engine";
import { join, toFileUrl } from "@std/path";
import { join, SEPARATOR, toFileUrl } from "@std/path";

const visit = (
program: ParsedSource,
Expand Down Expand Up @@ -67,7 +67,7 @@ const importsFrom = async (path: string): Promise<string[]> => {
return [...imports.values()];
};

const localAppsFolder = `${Deno.cwd()}/apps`;
const localAppsFolder = `${Deno.cwd().replaceAll(SEPARATOR, "/")}/apps`;

const skipPath = (path: string) => {
if (path.endsWith(".tsx")) {
Expand Down
5 changes: 3 additions & 2 deletions dev/tailwind.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { cyan } from "@std/fmt/colors";
import { walk } from "@std/fs";
import { join, toFileUrl } from "@std/path";
import { join, SEPARATOR, toFileUrl } from "@std/path";
import autoprefixer from "npm:[email protected]";
import cssnano from "npm:[email protected]";
import postcss, { type AcceptedPlugin } from "npm:[email protected]";
Expand Down Expand Up @@ -87,7 +87,8 @@ const withReleaseContent = async (config: Config) => {
includeFiles: true,
})
) {
if (entry.path.endsWith(".tsx") || entry.path.includes("/apps/")) {
const path = entry.path.replaceAll(SEPARATOR, "/");
if (path.endsWith(".tsx") || path.includes("/apps/")) {
roots.add(toFileUrl(entry.path).href);
}
}
Expand Down

0 comments on commit 8bde8b5

Please sign in to comment.