pub struct App {
pub root: PathBuf,
}Expand description
One located Frame application.
Fields§
§root: PathBufThe application root: the directory holding frame.toml.
Implementations§
Source§impl App
impl App
Sourcepub fn find(start: &Path) -> Result<Self, CliError>
pub fn find(start: &Path) -> Result<Self, CliError>
Locates the application whose tree contains start, walking parent
directories until a frame.toml is found.
§Errors
Returns CliError::NotAnApplication when no ancestor holds a
frame.toml.
Sourcepub fn find_from_current_dir() -> Result<Self, CliError>
pub fn find_from_current_dir() -> Result<Self, CliError>
Locates the application containing the current directory.
§Errors
Fails when the current directory is unreadable or no ancestor holds a
frame.toml.
Sourcepub fn config_path(&self) -> PathBuf
pub fn config_path(&self) -> PathBuf
The application’s frame.toml path.
Sourcepub fn component_dir(&self) -> PathBuf
pub fn component_dir(&self) -> PathBuf
The component directory.
Sourcepub fn load_config(&self) -> Result<FrameConfig, CliError>
pub fn load_config(&self) -> Result<FrameConfig, CliError>
Loads and validates the application’s stated config through the host’s own loader — the CLI never grows a second parser.
§Errors
Surfaces the host’s typed load failure, naming the file.
Sourcepub fn page_toolchain_installed(&self) -> bool
pub fn page_toolchain_installed(&self) -> bool
True when the page’s type/proof toolchain is installed
(page/node_modules exists).
Sourcepub fn stale_page_sources(&self) -> Result<Vec<PathBuf>, CliError>
pub fn stale_page_sources(&self) -> Result<Vec<PathBuf>, CliError>
Every page source whose compiled module is missing or older than the source — empty means the compiled page is current. A tsconfig newer than a compiled module also marks that module stale, since compiler options shape the output.
§Errors
Fails loudly on an unreadable page tree.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for App
impl RefUnwindSafe for App
impl Send for App
impl Sync for App
impl Unpin for App
impl UnsafeUnpin for App
impl UnwindSafe for App
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request