Token导航 LogoToken导航

Agent Skill · 开发

use-railway(使用铁路)

use-railway 用于处理 GitHub 仓库、Issue、Pull Request 和代码协作信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要围绕仓库状态、代码变更或协作事项进行整理时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

use-railway 是开发类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为接触敏感数据;许可证信息还不明确,第三方扫描有未通过项,按安装量在开发类的 21,746 个 Skill 里排第 579。

总安装 72,720周安装 2,961GitHub Stars 253下载 23,760核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:use-railway(使用铁路)
来源仓库:https://github.com/railwayapp/railway-skills
仓库路径:skills/use-railway
安装命令:
npx skills add https://github.com/railwayapp/railway-skills --skill use-railway
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/railwayapp/railway-skills --skill use-railway

这个 Skill 是做什么的

开发类 Skill 面向写代码、改代码和排查问题,一般会读写仓库文件,部分还会执行构建或测试命令。

完整的铁路基础设施管理:项目、服务、数据库、部署、环境、对象存储和故障排除。

通过 CLI 上下文管理跨 Railway 的资源层次结构进行操作:工作区、项目、环境、服务、存储桶和部署 涵盖五个操作领域:资源设置、代码部署、配置管理、健康监控和 API/文档访问 包括预检身份验证检查、上下文解析和常见工作流程(例如首次部署、添加对象存储和故障恢复)的多步骤组合模式 支持 CLI 命令和 GraphQL API 回退,以执行 CLI 未公开的操作;所有输出都使用 --json 为了可靠的解析

来源仓库内路径:skills/use-railway

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/railwayapp/railway-skills --skill use-railway;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要接触敏感数据,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

use-railway 怎么安装?

在终端执行 npx skills add https://github.com/railwayapp/railway-skills --skill use-railway。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

use-railway 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

use-railway 需要什么权限?

权限级别是接触敏感数据。该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

use-railway 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

use-railway 用的人多吗?

公开数据是累计安装 72,720 次,近一周安装 2,961 次,下载 23,760 次,GitHub 253 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

use-railway 安全吗?

第三方扫描有未通过项,风险较高。除非你确认过源码,否则不建议直接安装到常用环境。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。

先想清楚的地方

  • 需要接触敏感数据,装到常用环境前要先评估影响面。
  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方扫描存在提醒项或未通过项,需要人工逐条确认。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理开发类任务、又不想每次都手写提示词的人。

不太适合

  • 环境里有大量密钥、凭证,不方便给第三方 Skill 读取的人。
  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

开发类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
skill-vetter

技能审查员 · OpenClaw

8,779,018986操作浏览器MIT-0通过
ontology

本体论 · OpenClaw

6,636,960576只读MIT-0通过
entra-app-registration

内部应用程序注册 · Codex、Claude

6,631,872764接触敏感数据未明确通过
entra-app-registration

内部应用程序注册 · Codex、Claude

3,757,680201接触敏感数据未明确通过
nano-banana-pro

纳米香蕉专业版 · OpenClaw

3,526,898364接触敏感数据MIT-0有提醒
use-railway

使用铁路 · 本页

72,720253接触敏感数据未明确未通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Use Railway

Railway resource model

Railway organizes infrastructure in a hierarchy:

  • Workspace is the billing and team scope. A user belongs to one or more workspaces.
  • Project is a collection of services under one workspace. It maps to one deployable unit of work.
  • Environment is an isolated configuration plane inside a project (for example, production, staging). Each environment has its own variables, config, and deployment history.
  • Service is a single deployable unit inside a project. It can be an app from a repo, a Docker image, or a managed database.
  • Bucket is an S3-compatible object storage resource inside a project. Buckets are created at the project level and deployed to environments. Each bucket has credentials (endpoint, access key, secret key) for S3-compatible access.
  • Deployment is a point-in-time release of a service in an environment. It has build logs, runtime logs, and a status lifecycle.

Most CLI commands operate on the linked project/environment/service context. Use railway status --json to see the context, and --project, --environment, --service flags to override.

Parsing Railway URLs

Users often paste Railway dashboard URLs. Extract IDs before doing anything else:

https://railway.com/project/<PROJECT_ID>/service/<SERVICE_ID>?environmentId=<ENV_ID>
https://railway.com/project/<PROJECT_ID>/service/<SERVICE_ID>

The URL always contains projectId and serviceId. It may contain environmentId as a query parameter. If the environment ID is missing and the user specifies an environment by name (e.g., "production"), resolve it:

scripts/railway-api.sh \
  'query getProject($id: String!) {
    project(id: $id) {
      environments { edges { node { id name } } }
    }
  }' \
  '{"id": "<PROJECT_ID>"}'

Match the environment name (case-insensitive) to get the environmentId.

Prefer passing explicit IDs to CLI commands (--project, --environment, --service) and scripts (--project-id, --environment-id, --service-id) instead of running railway link. This avoids modifying global state and is faster.

Preflight

Before any mutation, verify context:

command -v railway                # CLI installed
railway whoami --json             # authenticated
railway --version                 # check CLI version

Context resolution — URL IDs always win:

  • If the user provides a Railway URL, extract IDs from it. Do NOT run railway status --json — it returns the locally linked project, which is usually unrelated.
  • If no URL is given, fall back to railway status --json for the linked project/environment/service.

If the CLI is missing, guide the user to install it.

bash <(curl -fsSL cli.new) # Shell script (macOS, Linux, Windows via WSL)
brew install railway # Homebrew (macOS)
npm i -g @railway/cli # npm (macOS, Linux, Windows). Requires Node.js version 16 or higher.

If not authenticated, run railway login. If not linked and no URL was provided, run railway link --project <id-or-name>.

If a command is not recognized (for example, railway environment edit), the CLI may be outdated. Upgrade with:

railway upgrade

Common quick operations

These are frequent enough to handle without loading a reference:

railway status --json                                    # current context
railway whoami --json                                    # auth and workspace info
railway project list --json                              # list projects
railway service status --all --json                      # all services in current context
railway variable list --service <svc> --json             # list variables
railway variable set KEY=value --service <svc>           # set a variable
railway logs --service <svc> --lines 200 --json          # recent logs
railway up --detach -m "<summary>"                       # deploy current directory
railway bucket list --json                               # list buckets in current environment
railway bucket info --bucket <name> --json               # bucket storage and object count
railway bucket credentials --bucket <name> --json        # S3-compatible credentials

Routing

For anything beyond quick operations, load the reference that matches the user's intent. Load only what you need, one reference is usually enough, two at most.

IntentReferenceUse for
Analyze a database ("analyze <url>", "analyze db", "analyze database", "analyze service", "introspect", "check my postgres/redis/mysql/mongo")analyze-db.mdDatabase introspection and performance analysis. analyze-db.md directs you to the DB-specific reference. This takes priority over the status/operate routes when a Railway URL to a database service is provided alongside "analyze".
Create or connect resourcessetup.mdProjects, services, databases, buckets, templates, workspaces
Ship code or manage releasesdeploy.mdDeploy, redeploy, restart, build config, monorepo, Dockerfile
Change configurationconfigure.mdEnvironments, variables, config patches, domains, networking
Check health or debug failuresoperate.mdStatus, logs, metrics, build/runtime triage, recovery
Request from API, docs, or communityrequest.mdRailway GraphQL API queries/mutations, metrics queries, Central Station, official docs

If the request spans two areas (for example, "deploy and then check if it's healthy"), load both references and compose one response.

Execution rules

  1. Prefer Railway CLI. Fall back to scripts/railway-api.sh for operations the CLI doesn't expose.
  2. Use --json output where available for reliable parsing.
  3. Resolve context before mutation. Know which project, environment, and service you're acting on.
  4. For destructive actions (delete service, remove deployment, drop database), confirm intent and state impact before executing.
  5. After mutations, verify the result with a read-back command.

User-only commands (NEVER execute directly)

These commands modify database state and require the user to run them directly in their terminal. Do NOT execute these with Bash. Instead, show the command and ask the user to run it.

CommandWhy user-only
python3 scripts/enable-pg-stats.py --service <name>Modifies shared_preload_libraries, may restart database
python3 scripts/pg-extensions.py --service <name> install <ext>Installs database extension
python3 scripts/pg-extensions.py --service <name> uninstall <ext>Removes database extension
ALTER SYSTEM SET...Changes PostgreSQL configuration
DROP EXTENSION...Removes database extension
CREATE EXTENSION...Installs database extension

When these operations are needed:

  1. Explain what the command does and any side effects (e.g., restart required)
  2. Show the exact command the user should run
  3. Wait for user confirmation that they ran it
  4. Verify the result with a read-only query

Composition patterns

Multi-step workflows follow natural chains:

  • Add object storage: setup (create bucket), setup (get credentials), configure (set S3 variables on app service)
  • First deploy: setup (create project + service), configure (set variables and source), deploy, operate (verify healthy)
  • Fix a failure: operate (triage logs), configure (fix config/variables), deploy (redeploy), operate (verify recovery)
  • Add a domain: configure (add domain + set port), operate (verify DNS and service health)
  • Docs to action: request (fetch docs answer), route to the relevant operational reference

When composing, return one unified response covering all steps. Don't ask the user to invoke each step separately.

Setup decision flow

When the user wants to create or deploy something, determine the right action from current context:

  1. Run railway status --json in the current directory.
  2. If linked: add a service to the existing project (railway add --service <name>). Do not create a new project unless the user explicitly says "new project" or "separate project".
  3. If not linked: check the parent directory (cd.. && railway status --json).

- Parent linked: this is likely a monorepo sub-app. Add a service and set rootDirectory to the sub-app path. - Parent not linked: run railway list --json and look for a project matching the directory name. - Match found: link to it (railway link --project <name>). - No match: create a new project (railway init --name <name>).

  1. When multiple workspaces exist, match by name from railway whoami --json.

Naming heuristic: app names like "flappy-bird" or "my-api" are service names, not project names. Use the directory or repo name for the project.

Response format

For all operational responses, return:

  1. What was done (action and scope).
  2. The result (IDs, status, key output).
  3. What to do next (or confirmation that the task is complete).

Keep output concise. Include command evidence only when it helps the user understand what happened.

平台分布

Codex

36.18%
按下载量换算8,596

Claude

29.66%
按下载量换算7,047

Cursor

16.31%
按下载量换算3,875

Gemini CLI

9.2%
按下载量换算2,186

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

未通过

权限和风险

接触敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在提醒或未通过项,安装前请自行复核。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills