### Initialize Repobot Configuration Source: https://github.com/rnd-pro/repobot/blob/main/README.md Initializes a new configuration file for Repobot in your project, guiding you through the setup process. ```bash npx @rnd-pro/repobot init ``` -------------------------------- ### Install Repobot NPM Package Source: https://github.com/rnd-pro/repobot/blob/main/README.md Installs the Repobot package using npm, making it available for use in your project. ```bash npm install @rnd-pro/repobot ``` -------------------------------- ### Monitor Repository with Repobot CLI Source: https://github.com/rnd-pro/repobot/blob/main/README.md Starts Repobot in watch mode to automatically monitor the repository and generate reports. ```bash repobot watch ``` -------------------------------- ### Configure TypeScript for JSDoc Type Checking Source: https://github.com/rnd-pro/repobot/blob/main/TYPE-CHECKING.md This `tsconfig.json` configuration enables TypeScript to check JavaScript files (`allowJs: true`, `checkJs: true`) without emitting any compiled output (`noEmit: true`). This setup is crucial for projects that use JSDoc for type annotations in a JavaScript-first environment. ```JSON { "compilerOptions": { "allowJs": true, "noEmit": true, "checkJs": true } } ``` -------------------------------- ### Define Complex Type with JSDoc @typedef Source: https://github.com/rnd-pro/repobot/blob/main/TYPE-CHECKING.md This JavaScript example illustrates how to define a complex object type using JSDoc's `@typedef` and `@property` tags directly within a JavaScript file. This allows for structured type definitions that can then be referenced by other JSDoc annotations, like for function parameters. ```JavaScript /** * @typedef {Object} User * @property {String} id - User ID * @property {String} name - User name * @property {Number} age - User age * @property {Boolean} isActive - Whether user is active */ /** * @param {User} user - User object */ function processUser(user) { // Implementation } ``` -------------------------------- ### Initialize Repobot Configuration via CLI Source: https://github.com/rnd-pro/repobot/blob/main/README.md Initializes a new configuration file for Repobot in the current project directory. ```bash repobot init ``` -------------------------------- ### Display Repobot CLI Help Source: https://github.com/rnd-pro/repobot/blob/main/README.md Shows all available commands and options for the Repobot command-line interface. ```bash repobot --help ``` -------------------------------- ### Initialize and Use Repobot with TypeScript Source: https://github.com/rnd-pro/repobot/blob/main/README.md Demonstrates how to import and initialize the Repobot class in a TypeScript project, showcasing type-safe interaction for generating reports. ```typescript import { Repobot } from '@rnd-pro/repobot'; // Initialize Repobot with configuration const repobot = new Repobot({ ai: { apiKey: process.env.AI_API_KEY, endpoint: 'https://api.openai.com/v1/chat/completions', }, }); // Use Repobot with full TypeScript type checking async function generateReport() { const report = await repobot.generateReport('daily'); console.log(report); } ``` -------------------------------- ### Run Repobot Source: https://github.com/rnd-pro/repobot/blob/main/README.md Executes Repobot, allowing it to perform its configured tasks such as generating reports or monitoring the repository. ```bash npx @rnd-pro/repobot run ``` -------------------------------- ### Manage Repobot Tasks via CLI Source: https://github.com/rnd-pro/repobot/blob/main/README.md Allows listing all tracked tasks and marking specific tasks as completed. ```bash repobot tasks list repobot tasks complete ``` -------------------------------- ### Display Repobot Repository Insights via CLI Source: https://github.com/rnd-pro/repobot/blob/main/README.md Provides AI-powered insights and summaries about the repository's status and activity. ```bash repobot insights ``` -------------------------------- ### Repobot Development Scripts Source: https://github.com/rnd-pro/repobot/blob/main/README.md Common npm scripts for development tasks such as type checking, running tests, linting, and code formatting. ```bash # Run type checking npm run typecheck # Run tests npm test # Lint code npm run lint # Format code npm run format ``` -------------------------------- ### Run Project Tests Source: https://github.com/rnd-pro/repobot/blob/main/CONTRIBUTING.md This command executes the test suite for the Repobot project. It utilizes Node.js's built-in test runner to ensure code functionality, validate changes, and prevent regressions, which is a crucial step before submitting a pull request. ```bash npm test ``` -------------------------------- ### Check and Format JavaScript Code Source: https://github.com/rnd-pro/repobot/blob/main/CONTRIBUTING.md These commands are used to enforce code style and perform type checking for JavaScript files within the Repobot project. 'npm run lint' checks for style violations, 'npm run format' automatically formats the code according to Prettier rules, and 'npm run typecheck' verifies type correctness using the configured type checker. ```bash npm run lint npm run format npm run typecheck ``` -------------------------------- ### Repobot Configuration File Structure Source: https://github.com/rnd-pro/repobot/blob/main/README.md Defines the structure and available options for the `repobot.config.js` file, used to customize Repobot's behavior, including AI, Telegram, reporting, and repository settings. ```APIDOC export default { ai: { apiKey: process.env.AI_API_KEY, model: 'gpt-4', // or other models endpoint: 'https://api.openai.com/v1/chat/completions', // or other AI provider endpoints }, telegram: { botToken: process.env.TELEGRAM_BOT_TOKEN, chatId: process.env.TELEGRAM_CHAT_ID, // for direct messages groupId: process.env.TELEGRAM_GROUP_ID, // for group messages }, reporting: { schedule: '0 9 * * 1-5', // daily at 9 AM on weekdays template: 'daily', // or 'weekly', 'monthly', 'custom' }, repository: { paths: { todos: ['**/TODO.md', '**/TODO'], documentation: ['**/*.md'], }, }, }; ``` -------------------------------- ### Generate Repobot Reports via CLI Source: https://github.com/rnd-pro/repobot/blob/main/README.md Generates various types of reports (daily, weekly, monthly) based on repository activity. ```bash repobot report daily repobot report weekly repobot report monthly ``` -------------------------------- ### Run Type Checks with TypeScript CLI Source: https://github.com/rnd-pro/repobot/blob/main/TYPE-CHECKING.md This Bash command executes the TypeScript compiler (`tsc`) to perform type checking across the project. The `--noEmit` flag ensures that no JavaScript files are generated, making it suitable for validating JSDoc-annotated JavaScript code without a build step. ```Bash npx tsc --noEmit ``` -------------------------------- ### Define Object Type with JSDoc for Function Parameters Source: https://github.com/rnd-pro/repobot/blob/main/TYPE-CHECKING.md This JavaScript snippet demonstrates how to define an object type for a function parameter using JSDoc's `{Object}` syntax. It ensures that the `settings` parameter is an object where keys are strings and values are strings. ```JavaScript /** * @param {Object} settings - User settings object */ function updateSettings(settings) { // Implementation } ``` -------------------------------- ### Send Repobot Reports via Telegram CLI Source: https://github.com/rnd-pro/repobot/blob/main/README.md Sends generated daily or weekly reports to configured Telegram chats. ```bash repobot send daily repobot send weekly ``` -------------------------------- ### Define Complex Type in TypeScript Declaration File Source: https://github.com/rnd-pro/repobot/blob/main/TYPE-CHECKING.md This TypeScript snippet demonstrates how to define a complex interface within a `.d.ts` declaration file. Using `declare namespace` helps organize global types and ensures type safety for complex data structures across the project. ```TypeScript declare namespace App { interface User { id: String; name: String; age: Number; isActive: Boolean; } } ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.