xanobius/notion-notifier
Composer 安装命令:
composer require xanobius/notion-notifier
包简介
Command to update notion.io information
README 文档
README
Keep all your projects and their version under control!
Notion-Notifier is a small package to submit the current versions to a notion page.
The aim is to update the version of the used framework (symfony, pimcore, laravel, drupal...) as well as the version of your codebase (git tag).
The package can be used agnostic or with a little more comfort in laravel.
Perparation
This package has list of project in mind, collected in a notion database. In a database, each entry is a distinct notion page with the properties of the database.
In this Example we would have the two columns FW-Version (Framework) and CB-Version (Code-Base) we want to populate on every update with the new, actual values. To update something, we must have something, meaning:
- Notion account with a project database
- Notion API Secret
- The id of the notion page
- The names of the page properties
Installation
Use the package manager composer to install notion-notifier.
composer require xanobius/notion-notifier
Usage (agnostic)
use Xanobius\NotionNotifier\NotionNotifier; $notifier = new NotionNotifier; $notifier->setPageId('[YOUR PAGE ID]'); $notifier->setNotionSecret('[YOUR NOTION SECRET]'); try{ $notifier->updatePageValue('[PROPERTY NAME]', '[NEW VALUE]'); }catch(Exception $e){ // do your error handling here }
Usage in Laravel
Right after the installation, the .env file awaits your settings
NOTION_SECRET= NOTION_PAGE_ID= NOTION_LARAVEL_PROP= NOTION_GIT_PROP=
with those options set, one can just call the command
php artisan notion-notifier:version
The command submits code-base and framework version to the specific properties and can be called after deployment. To change the behaviour of the package, the config can be published and adjusted to your needs.
sail artisan vendor:publish --provider="Xanobius\NotionNotifier\NotionNotifierServiceProvider" --tag="config"
Next steps...
Integration for symfony/pimcore projects with config as well.
Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Please make sure to update tests as appropriate.
License
xanobius/notion-notifier 适用场景与选型建议
xanobius/notion-notifier 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 27 次下载、GitHub Stars 达 0, 最近一次更新时间为 2022 年 07 月 17 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 xanobius/notion-notifier 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 xanobius/notion-notifier 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 27
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 8
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2022-07-17
