small cleanup
This commit is contained in:
parent
d8fd1ae771
commit
93a9ce9c8c
|
|
@ -6,12 +6,11 @@ import { join, extname } from "path"
|
||||||
|
|
||||||
import type { CommandOutput } from "@/shared/types"
|
import type { CommandOutput } from "@/shared/types"
|
||||||
import { isBinaryFile } from "@/utils"
|
import { isBinaryFile } from "@/utils"
|
||||||
import { projectName, projectDir } from "@/project"
|
import { projectDir } from "@/project"
|
||||||
import { sessionGet } from "@/session"
|
import { sessionGet } from "@/session"
|
||||||
import { highlight } from "../lib/highlight"
|
import { highlight } from "../lib/highlight"
|
||||||
|
|
||||||
export default async function (path: string) {
|
export default async function (path: string) {
|
||||||
const project = projectName()
|
|
||||||
const root = sessionGet("cwd") || projectDir()
|
const root = sessionGet("cwd") || projectDir()
|
||||||
|
|
||||||
let files: string[] = []
|
let files: string[] = []
|
||||||
|
|
|
||||||
|
|
@ -10,7 +10,6 @@ import { projectName, projectDir } from "@/project"
|
||||||
import { sessionGet } from "@/session"
|
import { sessionGet } from "@/session"
|
||||||
|
|
||||||
export default async function (path: string) {
|
export default async function (path: string) {
|
||||||
const project = projectName()
|
|
||||||
const root = sessionGet("cwd") || projectDir()
|
const root = sessionGet("cwd") || projectDir()
|
||||||
|
|
||||||
let files: string[] = []
|
let files: string[] = []
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
// Look around.
|
// Look around.
|
||||||
|
|
||||||
import { readdirSync } from "fs"
|
import { readdirSync } from "fs"
|
||||||
import { projectName, projectDir } from "@/project"
|
import { projectDir } from "@/project"
|
||||||
import { sessionGet } from "@/session"
|
import { sessionGet } from "@/session"
|
||||||
|
|
||||||
export default function () {
|
export default function () {
|
||||||
|
|
|
||||||
|
|
@ -29,7 +29,7 @@ export function projectDir(name = projectName()): string {
|
||||||
}
|
}
|
||||||
|
|
||||||
export function projectBin(name = projectName()): string {
|
export function projectBin(name = projectName()): string {
|
||||||
return join(projectDir(), "bin")
|
return join(projectDir(name), "bin")
|
||||||
}
|
}
|
||||||
|
|
||||||
export function projectFiles(name = projectName()): Dirent[] {
|
export function projectFiles(name = projectName()): Dirent[] {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user