Skip to content

Commit 3210970

Browse files
Merge pull request #899 from codeflash-ai/fix-docs-url
fix docs link
2 parents 630ca8a + f2d2bd3 commit 3210970

File tree

2 files changed

+30
-16
lines changed

2 files changed

+30
-16
lines changed

codeflash/code_utils/env_utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ def get_codeflash_api_key() -> str:
7676
# within the same process, the environment variable could become outdated.
7777
api_key = shell_api_key or env_api_key if is_LSP_enabled() else env_api_key or shell_api_key
7878

79-
api_secret_docs_message = "For more information, refer to the documentation at [https://docs.codeflash.ai/getting-started/codeflash-github-actions#add-your-api-key-to-your-repository-secrets]." # noqa
79+
api_secret_docs_message = "For more information, refer to the documentation at [https://docs.codeflash.ai/optimizing-with-codeflash/codeflash-github-actions#manual-setup]." # noqa
8080
if not api_key:
8181
msg = (
8282
"I didn't find a Codeflash API key in your environment.\nYou can generate one at "

docs/getting-started/local-installation.mdx

Lines changed: 29 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -55,20 +55,6 @@ poetry add codeflash@latest --group dev
5555
</Tip>
5656
</Step>
5757

58-
<Step title="Generate a Codeflash API Key">
59-
Codeflash uses cloud-hosted AI models and integrations with GitHub. You'll need an API key to authorize your access.
60-
61-
1. Visit the [Codeflash Web App](https://app.codeflash.ai/)
62-
2. Sign up with your GitHub account (free)
63-
3. Navigate to the [API Key](https://app.codeflash.ai/app/apikeys) page to generate your API key
64-
65-
<Note>
66-
**Free Tier Available**
67-
68-
Codeflash offers a **free tier** with a limited number of optimizations. Perfect for trying it out on small projects!
69-
</Note>
70-
</Step>
71-
7258
<Step title="Run Automatic Configuration">
7359
Navigate to your project's root directory (where your `pyproject.toml` file is or should be) and run:
7460

@@ -95,10 +81,38 @@ When running `codeflash init`, you will see the following prompts:
9581
5. Which test framework do you use? (pytest/unittest)
9682
6. Install GitHub actions for Continuous optimization?
9783
```
84+
85+
After you have answered these questions, the Codeflash configuration will be saved in the `pyproject.toml` file.
9886
</Step>
87+
88+
<Step title="Generate a Codeflash API Key">
89+
Codeflash uses cloud-hosted AI models and integrations with GitHub. You'll need an API key to authorize your access.
90+
91+
1. Visit the [Codeflash Web App](https://app.codeflash.ai/)
92+
2. Sign up with your GitHub account (free)
93+
3. Navigate to the [API Key](https://app.codeflash.ai/app/apikeys) page to generate your API key
94+
95+
<Note>
96+
**Free Tier Available**
97+
98+
Codeflash offers a **free tier** with a limited number of optimizations. Perfect for trying it out on small projects!
99+
</Note>
100+
</Step>
101+
102+
<Step title="Install the Codeflash GitHub App">
103+
104+
{/* TODO: Justify to users Why we need the user to install Github App even in local Installation or local optimization? */}
105+
Finally, if you have not done so already, Codeflash will ask you to install the GitHub App in your repository.
106+
The Codeflash GitHub App allows access to your repository to the codeflash-ai bot to open PRs, review code, and provide optimization suggestions.
107+
108+
Please [install the Codeflash GitHub
109+
app](https://github.com/apps/codeflash-ai/installations/select_target) by choosing the repository you want to install
110+
Codeflash on.
111+
</Step>
112+
113+
99114
</Steps>
100115

101-
After you have answered these questions, the Codeflash configuration will be saved in the `pyproject.toml` file.
102116
To understand the configuration options, and set more advanced options, see the [Manual Configuration](/configuration) page.
103117

104118
### Step 4: Install the Codeflash GitHub App

0 commit comments

Comments
 (0)