resume/cli

该包已被废弃,不再维护。未建议替代包。

基于JSON文件生成漂亮的HTML简历。

dev-master 2019-05-06 18:27 UTC

This package is auto-updated.

Last update: 2020-02-06 20:24:26 UTC


README

resume-cli

Resume CLI

Latest Version on Packagist Total Downloads Software License Build Status StyleCI

基于JSON文件生成漂亮的HTML简历。您可以使用[预构建模板],下载 一个现成的模板,或者使用HTML和CSS[创建自己的模板]。

Resume CLI受到JSON Resume的启发(并略有借鉴),使用Laravel Zero构建。

索引

安装

您需要遵循几个简单的步骤来安装此包。

下载

通过 composer

$ composer global require resume/cli

或者在 composer.json 中添加包到依赖项,并在命令行中运行 composer global update 来下载包

{
    "require": {
        "resume/cli": "^1.0"
    }
}

确保Composer的全局bin目录包含在您的路径中。此目录位于macOS / Linux的~/.composer/vendor/bin,以及Windows的%APPDATA%/Composer/vendor/bin

使用

要创建简历,创建一个名为 resume.json 的文件,包含以下内容

{
    "name": "John Doe",
    "email": "john@example.com"
}

运行 resume make 将创建一个新文件夹(默认为 resume/),其中包含用于发布和分发您的简历所需的HTML和CSS。

注意:如果文件夹 resume 已存在,则命令将退出而不会更改或覆盖任何内容。

自定义

当然,您可能希望自定义简历的生成方式。您可以通过向 resume make 传递以下选项来实现这一点

源文件名

要更改用于生成简历的文件,请将文件名传递给 make 命令

$ resume make source.json

输出目录

要指定生成的简历的输出目录的名称,请使用 --output 选项

$ resume make source.json --output="public"

这将在其中创建一个 public 文件夹,并将生成的HTML和CSS放在那里。

强制生成

您可以使用 --force 标志来覆盖输出目录中已存在的文件或文件夹

$ resume make --output="public" --force

主题

您可以使用 --theme 选项选择不同的主题

# Generate your CV using the "flat" theme.
$ resume make source.json --theme="flat"

有关添加和编写自己的主题的更多信息,请参阅此处

预览您的简历

当然,在将其在线发布之前,您会想预览一下您的简历。您可以通过使用 serve 子命令来实现。

# Serve your CV from the default directory ('resume')
$ resume serve

# Serve your CV from a custom directory ('public', in this case)
$ resume serve public

这将启动 PHP 内置的 web 服务器,默认端口为 8000。要更改其服务的端口,请使用 --port 选项。

# Serve the CV on port 1337 instead of 8000
$ resume serve --port=1337

贡献

欢迎所有贡献(拉取请求、问题和功能请求)。不过,请先阅读 CONTRIBUTING.md。查看 贡献者页面 了解所有贡献者。

许可

resume/cli 遵循 MIT 许可证(MIT)。有关更多信息,请参阅 许可文件