import * as os from "os" ; import * as path from "path" ; import * as types from "./types" ; export const MINICONDA_DIR_PATH = process . env [ "CONDA" ] || "" ; export const IS_WINDOWS = process . platform === "win32" ; export const IS_MAC = process . platform === "darwin" ; export const IS_LINUX = process . platform === "linux" ; export const IS_UNIX = IS_MAC || IS_LINUX ; export const MINICONDA_BASE_URL = "https://repo.anaconda.com/miniconda/" ; /** Processor architectures supported by Miniconda */ export const MINICONDA_ARCHITECTURES = { x64 : "x86_64" , x86 : "x86" , ARM64 : "aarch64" , ARM32 : "armv7l" , } ; /** Processor architectures supported by Miniforge */ export const MINIFORGE_ARCHITECTURES = { x64 : "x86_64" , x86_64 : "x86_64" , aarch64 : "aarch64" , ppc64le : "ppc64le" , arm64 : "arm64" , } ; export const OS_NAMES = { win32 : "Windows" , darwin : "MacOSX" , linux : "Linux" , } ; /** Common download prefix */ export const MINIFORGE_URL_PREFIX = "https://github.com/conda-forge/miniforge/releases" ; /** Default miniforge if only miniforge-version is provided */ export const MINIFORGE_DEFAULT_VARIANT = "Miniforge3" ; /** Default miniforge if only miniforge-variant is provided */ export const MINIFORGE_DEFAULT_VERSION = "latest" ; /** Names for a conda `base` env */ export const BASE_ENV_NAMES = [ "root" , "base" , "" ] ; /**
 * Known extensions for `constructor`-generated installers supported
 */ export const KNOWN_EXTENSIONS = [ ".exe" , ".sh" ] ; /** As of mamba 0.7.6, only these top-level commands are supported */ export const MAMBA_SUBCOMMANDS = [ "clean" , "create" , "env" , "info" , "install" , "list" , "run" , "search" , ] ; /**
 * Errors that are always probably spurious
 */ export const IGNORED_WARNINGS = [ `menuinst_win32` , `Unable to register environment` , `0%|` , `Please run using "bash"` , `Key 'use_only_tar_bz2' is not a known primitive parameter.` , `moving to the top` , ] ; /**
 * Warnings that should be errors
 */ export const FORCED_ERRORS = [ `EnvironmentSectionNotValid` , ] ; /**
 * Avoid spurious conda warnings before we have a chance to update them
 */ export const BOOTSTRAP_CONDARC = "notify_outdated_conda: false" ; /**
 * The conda config file
 */ export const CONDARC_PATH = path . join ( os . homedir ( ) , ".condarc" ) ; /** Where to put files. Should eventually be configurable */ export const CONDA_CACHE_FOLDER = "conda_pkgs_dir" ; /** The environment variable exported */ export const ENV_VAR_CONDA_PKGS = "CONDA_PKGS_DIR" ; /** Shell profiles names to update so `conda` works for *login shells* */ export const PROFILES = [ ".bashrc" , ".bash_profile" , ".config/fish/config.fish" , ".profile" , ".tcshrc" , ".xonshrc" , ".zshrc" , ".config/powershell/profile.ps1" , "Documents/PowerShell/profile.ps1" , "Documents/WindowsPowerShell/profile.ps1" , ] ; /** Folders that need user ownership on windows */ export const WIN_PERMS_FOLDERS = [ "condabin/" , "Scripts/" , "shell/" , "etc/profile.d/" , "/Lib/site-packages/xonsh/" , ] ; see https export const PYTHON_SPEC = /^(.*::)?python($|\s\=\<\>\!\|)/i ; /**
 * Output name for the effective environment-file path used.
 */ export const OUTPUT_ENV_FILE_PATH = "environment-file" ; /**
 * Output name for the effective environment-file file content used.
 */ export const OUTPUT_ENV_FILE_CONTENT = "environment-file-content" ; /**
 * Output name for whether the effective environment-file file was patched.
 */ export const OUTPUT_ENV_FILE_WAS_PATCHED = "environment-file-was-patched" ;