sergebulaev/youtube-skills / .codex-marketplace/youtube-skills
youtube-marketing
VerifiedPlan, write, and publish for YouTube and YouTube Shorts. Use when the user wants high-CTR video titles, an SEO description with chapters and links, a first-30-seconds retention script (or a 3-second Shorts hook), a designer-ready thumbnail brief, a community-tab post or poll, or a weekly upload plan. The user supplies the video; the skills produce the title, description, hook, and thumbnail brief, then on approval upload and schedule via the Publora API.
lib/_env.py
View on GitHub"""Internal helper to load .env when python-dotenv is available."""
from __future__ import annotations
import os
from pathlib import Path
_ENV_LOADED = False
#: The only variables a project .env may set. Anything the bundle *executes*
#: or routes traffic through has to come from the launch environment: a .env
#: that arrives with a clone, or that lands in a parent directory, is not a
#: trusted source for the name of a command to run.
_DOTENV_VARIABLES = (
"YOUTUBE_API_KEY", "PUBLORA_API_KEY", "YOUTUBE_PLATFORM_ID", "PIXFARO_TOKEN", "PIXFARO_API_KEY",
)
def env_candidates() -> list[Path]:
"""Where `load_env` looks, in order: upward from the cwd, then the repo root
(this file's parent's parent)."""
out: list[Path] = []
try:
from dotenv import find_dotenv
found = find_dotenv(usecwd=True)
if found:
out.append(Path(found))
except ImportError:
cur = Path.cwd()
for d in [cur, *cur.parents]:
if (d / ".env").is_file():
out.append(d / ".env")
break
root = Path(__file__).resolve().parents[1] / ".env"
if root not in out:
out.append(root)
return out
def load_env(force: bool = False) -> None:
"""Load environment variables from .env if python-dotenv is installed.
Safe no-op if python-dotenv is missing, preserving Tier 0 (manual)
zero-dependency operation. Searches upwards from the current working
directory and checks the repository root. Only bundle API credentials and
the platform id are loaded. Executables and transport settings must come
from the launch environment. Existing environment variables are preserved.
"""
global _ENV_LOADED
if _ENV_LOADED and not force:
return
try:
from dotenv import dotenv_values
for path in env_candidates():
if not path.is_file():
continue
values = dotenv_values(path)
for name in _DOTENV_VARIABLES:
value = values.get(name)
if value is not None:
os.environ.setdefault(name, value)
except ImportError:
pass
_ENV_LOADED = True
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| brainstormingobra/superpowersYou MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or planning anything new, in software or out of it (a talk, a business, a renovation). | Stars: 323k | Updated | Claude CodeCodex | Verified | Install |
| brand-guidelinesanthropics/skillsApplies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand colors or style guidelines, visual formatting, or company design standards apply. | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| frontend-designanthropics/skillsGuidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making choices that don't read as templated defaults. | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| mcp-builderanthropics/skillsGuide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when building MCP servers to integrate external APIs or services, whether in Python (FastMCP) or Node/TypeScript (MCP SDK). | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |