1个不稳定版本
0.1.0 | 2023年2月4日 |
---|
#735 in 身份验证
22每月下载次数
在 headhunter-cli 中使用
14KB
291 代码行
bump-my-resume
Headhunter的工具,可以自动更新简历
现在您只需在 https://dev.hh.ru/admin 注册应用程序并使用Selenium获取一次访问令牌。此工具将模拟求职网站的活动并保持您的简历处于顶部。
要求
- ChromeDriver
- Windows: windows-latest-chrome.ps1
- Linux: ubuntu-latest-chrome
- macOS: macos-latest-chrome
- 在 https://hh.ru 的账户
登录
密码
- 在 https://dev.hh.ru/admin 注册的应用程序
client_id
看起来像UWWE5NX5SXFVJAFVBDB3M1P8B7K3L0XK4HIJWFEPAZLW0CGRMUA997PG38I21C71
client_secret
看起来像GGIGAZEFM796C6ZSTV0O5UUNIY06GVTC45XFZKEUEEB9ZIMP2ZMICXVDGQBTF2BT
安装
# run ChromeDriver on the another thread (it should use port 9515)
chromedriver &
# pass authorization, this requires a ChromeDriver
cargo build --release
# replace it with your data
./target/release/headhunter-cli auth \
"client_id" \
"client_secret" \
"login" \
"password"
# credentials are written to response.json
cat response.json
# you can now use the CLI to update the latest date on your resume
./target/release/headhunter-cli bump
在Linux上构建静态链接的二进制文件
我发现这在远程机器上运行很有用。您需要添加一些软件包和musl目标来实现这一点。
# add musl-gcc command
sudo apt install musl-tools
# add linux musl target
rustup target add x86_64-unknown-linux-musl
# build statically linked binary
cargo build --release --target x86_64-unknown-linux-musl
# note: it's available in bit different directory
./target/x86_64-unknown-linux-musl/release/headhunter-cli --help
服务器配置
- 将
response.json
和./target/release/headhunter-cli
放在同一目录中,例如/root/bump-my-resume
- 运行
crontab -e
- 按照以下方式添加行:
0 */1 * * * cd /root/bump-my-resume && ./target/release/headhunter-cli bump >> out.txt 2>&1
依赖项
~10–24MB
~353K SLoC