diff --git a/generator/konfig-docs/blog/2023/08/21-serverless.mdx b/generator/konfig-docs/blog/2023/08/21-serverless.mdx index 0c939aca6..bdcb0afba 100644 --- a/generator/konfig-docs/blog/2023/08/21-serverless.mdx +++ b/generator/konfig-docs/blog/2023/08/21-serverless.mdx @@ -55,7 +55,7 @@ only thought-provoking opinions. Next, I transcribed these discussions onto a whiteboard, organizing them into -"Pro Serverless," "Anti Serverless," or "Neutral" categories, and then +"Pro Serverless," "Anti Serverless", or "Neutral" categories, and then clustering them into distinct opinions. Each section in this post showcases an opinion while referencing pertinent discussions. diff --git a/generator/konfig-docs/blog/2023/10/23-github-copilot.mdx b/generator/konfig-docs/blog/2023/10/23-github-copilot.mdx new file mode 100644 index 000000000..8ceb34899 --- /dev/null +++ b/generator/konfig-docs/blog/2023/10/23-github-copilot.mdx @@ -0,0 +1,386 @@ +--- +slug: github-copilot +title: "I Reviewed 1,000s of Opinions on GitHub Copilot" +authors: dylan +tags: [Engineering] +--- + +import Head from '@docusaurus/Head'; + + + I Reviewed 1,000s of Opinions on GitHub Copilot + + + +GitHub Copilot has recently taken the software engineering world by storm, +hitting a milestone of $100M ARR. This achievement alone qualifies it to be a +publicly listed company. Meanwhile, funding continues to flow into code-focused +LLM use cases. + + + +
GitHub Copilot crosses 100M ARR Milestone}> + ![100M ARR](./github-copilot-assets/slides/after/good-news/100m-arr.png) +
+
+ +
TabbyML Raising 3.2M for an open-source GitHub Copilot}> + ![TabbyML](./github-copilot-assets/slides/after/good-news/tabby.png) +
+
+ +
Tabnine raises $15.5M for AI that autocompletes code}> + ![Tabnine](./github-copilot-assets/slides/after/good-news/tabnine.png) +
+
+ +
Anysphere raises $8M from OpenAI to build an AI-powered IDE}> + ![Cursor](./github-copilot-assets/slides/after/good-news/cursor.png) +
+
+ +
CodiumAI raises $11M}> + ![Codium](./github-copilot-assets/slides/after/good-news/codium.png) +
+
+
+ +{/* TRUNCATE */} + +LLMs are causing a stir in the software engineering community, with some +developers praising the technology and others fearing it. The controversy +surrounding LLMs is so intense that it has even led to a lawsuit against GitHub +Copilot. + +
Lawsuit against GitHub Copilot}> + ![Lawsuit](./github-copilot-assets/slides/after/lawsuit.png) +
+ + +To understand how developers are receiving Copilot, I went to where +developers live: Reddit, Twitter, Hacker News, and YouTube. I parsed 1,000s of +discussions and synthesized my findings in this article, striving to present +only thought-provoking opinions. + +
+![funnel](../08/serverless-assets/funnel.png) +
+ +Next, I transcribed these discussions onto a whiteboard, organizing them into +"Anti-Copilot" (πŸ‘Ž), "Pro-Copilot" (πŸ‘), or "Neutral" (🧐) categories, and then clustering them +into distinct opinions. Each section in this post showcases an opinion while +referencing pertinent discussions. + +
+ ![Whiteboard](./github-copilot-assets/whiteboard.png) +
+ +## πŸ‘Ž Copilot produces bad results + +LLMs operate as probabilistic models, implying they aren't always correct. This +is especially true for Copilot, which is trained on a corpus of code that may +not be representative of the code that a developer writes. As a result, Copilot +can +produce consistently bad results. + + + +
Reddit}> + ![job-worry](./github-copilot-assets/slides/after/bad-results/job-worry.png) +
+
+ +
Reddit}> + ![clippy](./github-copilot-assets/slides/after/bad-results/clippy.png) +
+
+ +
Hacker News}> + ![disaster](./github-copilot-assets/slides/after/bad-results/disaster.png) +
+
+ +
Reddit}> + ![decades](./github-copilot-assets/slides/after/bad-results/decades.png) +
+
+ +
YouTube}> + ![months-bugs](./github-copilot-assets/slides/after/bad-results/months-bugs.png) +
+
+ +
Reddit}> + ![lying](./github-copilot-assets/slides/after/bad-results/lying.png) +
+
+ +
Hacker News}> + ![90-percent](./github-copilot-assets/slides/after/bad-results/90-percent.png) +
+
+ +
Reddit}> + ![fall-short](./github-copilot-assets/slides/after/bad-results/fall-short.png) +
+
+ +
Reddit}> + ![far-worse](./github-copilot-assets/slides/after/bad-results/far-worse.png) +
+
+ +
Hacker News}> + ![incorrect](./github-copilot-assets/slides/after/bad-results/incorrect.png) +
+
+
+ +#### Key Takeaway πŸ”‘ + +Developers expect reliability from their tools. + +Copilot is not reliable, and therefore, certain developers have a tough time +wrestling with its output. Copilot lies or produces bad results for a vast +majority of the time. This can be exceedingly frustrating for developers who are +expecting Copilot to deliver on its promise of writing code for you. After some +bad experiences, some developers have even stopped using Copilot altogether. + + +For people who worry about job security, fear nothing, because Copilot is not +going to replace you anytime soon. + + +## πŸ‘Ž Copilot creates more problems than solutions + +Copilot is a tool that is supposed to help developers write code. However, its +unreliable results creates more problems than solutions. + + + +
YouTube}> + ![screwed](./github-copilot-assets/slides/after/more-problems/screwed.png) +
+
+ +
Reddit}> + ![subtle-bugs](./github-copilot-assets/slides/after/more-problems/subtle-bugs.png) +
+
+ +
Reddit}> + ![hassle](./github-copilot-assets/slides/after/more-problems/hassle.png) +
+
+ +
Hacker News}> + ![caused-more-problems](./github-copilot-assets/slides/after/more-problems/caused-more-problems.png) +
+
+ +
Reddit}> + ![interferes](./github-copilot-assets/slides/after/more-problems/interferes.png) +
+
+ +
YouTube}> + ![junior-dev](./github-copilot-assets/slides/after/more-problems/junior-dev.png) +
+
+
+ +#### Key Takeaway πŸ”‘ + +Copilot can waste your time. + + Code requires 100% accuracy, and inaccuracy can lead you down a rabbit hole of + debugging. Often wasting time or flat out breaking your code. In some cases, + this is frustrating enough for developers to stop using Copilot altogether. + Just like managing a junior developer, Copilot requires a lot of oversight. + Sometimes subtle bugs can take more time to debug and fix than writing the code + yourself. For some developers who find the output to be too inaccurate, Copilot + becomes an interference and ultimately doesn't save them any time. + +## πŸ‘ Copilot helps you write software faster + +Despite the inaccuracy of LLMs, if you treat Copilot as a tool that can help +take care of the boring stuff, it can be a powerful tool. + + + +
Reddit}> + ![twice-as-fast](./github-copilot-assets/slides/after/faster-software/twice-as-fast.png) +
+
+ +
Hacker News}> + ![10-20-pct](./github-copilot-assets/slides/after/faster-software/10-20-pct.png) +
+
+ +
Reddit}> + ![worth-it](./github-copilot-assets/slides/after/faster-software/worth-it.png) +
+
+ +
Reddit}> + ![30-line-test](./github-copilot-assets/slides/after/faster-software/30-line-test.png) +
+
+ +
YouTube}> + ![boring-stuff](./github-copilot-assets/slides/after/faster-software/boring-stuff.png) +
+
+ +
Hacker News}> + ![mundane](./github-copilot-assets/slides/after/faster-software/mundane.png) +
+
+ +
Reddit}> + ![tedium](./github-copilot-assets/slides/after/faster-software/tedium.png) +
+
+ +
Reddit}> + ![hours-to-minutes](./github-copilot-assets/slides/after/faster-software/hours-to-minutes.png) +
+
+ +
Reddit}> + ![near-perfect](./github-copilot-assets/slides/after/faster-software/near-perfect.png) +
+
+
+ +#### Key Takeaway πŸ”‘ + +Copilot increases productivity. + +Often, developers face mundane and repetitive tasks. Given enough context, +Copilot can do these tasks for you with sufficient accuracy. For some +developers, these tasks can be a significant time sink, and Copilot can help you +get that time back. + +Based on the mentioned 10-20% increase in productivity, such an improvement is +substantial. For the sake of a conservative analysis, let's consider the lower +bound: if we assume an engineer is paid $100k/yr and becomes just 5% more +productive (half of the 10% reference), then with a yearly cost of +[$100](https://github.com/features/copilot#pricing) for Copilot, the tool brings +in an added value of $4900 for the company. + +## πŸ‘ Copilot helps you write better software + +Copilot can be a great learning tool for junior developers, giving tech leads +more time to focus on higher-level tasks. Ultimately leading to better software +and happier developers. + + + +
Hacker News}> + ![better-code-docs-tests](./github-copilot-assets/slides/after/better-software/better-code-docs-tests.png) +
+
+ +
Reddit}> + ![test-coverage](./github-copilot-assets/slides/after/better-software/test-coverage.png) +
+
+ +
Hacker News}> + ![higher-level](./github-copilot-assets/slides/after/better-software/higher-level.png) +
+
+ +
Hacker News}> + ![really-super-powers](./github-copilot-assets/slides/after/better-software/really-super-powers.png) +
+
+ +
x.com}> + ![super-power](./github-copilot-assets/slides/after/better-software/super-power.png) +
+
+ +
YouTube}> + ![amazing](./github-copilot-assets/slides/after/better-software/amazing.png) +
+
+
+ +#### Key Takeaway πŸ”‘ + +Copilot has enough intelligence to help you write better software. + +This holds especially true for junior developers still learning the ropes. It +can drastically make mundane tasks like documentation and testing easier, giving +developers more time to focus on the bigger picture while maintaining a high +standard of code quality. Multiplying this effect across an engineering team +leads to a higher quality codebaseβ€”the ultimate dream for engineering leaders. + +## 🧐 Copilot is like a calculator + +Copilot is a tool that can help you solve problems faster, but it is not a +replacement for your brain. You still need to know how to solve problems, and +you still need to know how to write code. + + + +
Reddit}> + ![not-equally-good](./github-copilot-assets/slides/after/calculator/not-equally-good.png) +
+
+ +
Reddit}> + ![cheating-math](./github-copilot-assets/slides/after/calculator/cheating-math.png) +
+
+ +
YouTube}> + ![corner-drag](./github-copilot-assets/slides/after/calculator/corner-drag.png) +
+
+ +
YouTube}> + ![interns](./github-copilot-assets/slides/after/calculator/interns.png) +
+
+ +
x.com}> + ![calculator](./github-copilot-assets/slides/after/calculator/calculator.png) +
+
+ +
Reddit}> + ![pros-cons](./github-copilot-assets/slides/after/calculator/pros-cons.png) +
+
+
+ +#### Key Takeaway πŸ”‘ + +Just as calculators enable mathematicians to solve problems more quickly, +Copilot spares developers from focusing on repetitive tasks. + +However, just like calculators, Copilot does not help you make sense of the +problem. You still need to know how to solve problems, and you still need to +know how to write code. + +# Conclusion + +Opinions on Copilot vary; some see it as a blessing, while others regard it as a +curse. For its proponents, Copilot is a valuable tool that enhances coding speed +and quality. However, critics argue it introduces more issues than it resolves. + +I suspect that the complexity of a task makes a big difference in the quality of +output. Working on tasks that require more context will inevitably lead to worse +results. Yet, when viewed simply as a tool to handle the mundane aspects of +coding, Copilot reveals its potential. + + +At [Konfig](https://konfigthis.com), we use Copilot and ChatGPT daily and have +found them to be incredibly useful. We are excited to see what the future holds +for LLMs and are looking forward to using more tools that help developers write +better. We would be very disappointed if we could not use Copilot anymore. + \ No newline at end of file diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/90-percent.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/90-percent.png new file mode 100644 index 000000000..da32609cd Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/90-percent.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/clippy.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/clippy.png new file mode 100644 index 000000000..e810006fc Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/clippy.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/decades.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/decades.png new file mode 100644 index 000000000..dc8732c40 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/decades.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/disaster.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/disaster.png new file mode 100644 index 000000000..8476c5348 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/disaster.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/fall-short.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/fall-short.png new file mode 100644 index 000000000..8f68d2104 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/fall-short.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/far-worse.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/far-worse.png new file mode 100644 index 000000000..8eaf74fc6 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/far-worse.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/incorrect.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/incorrect.png new file mode 100644 index 000000000..a145f9b0c Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/incorrect.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/job-worry.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/job-worry.png new file mode 100644 index 000000000..416435316 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/job-worry.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/lying.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/lying.png new file mode 100644 index 000000000..4a941520f Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/lying.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/months-bugs.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/months-bugs.png new file mode 100644 index 000000000..be5215e55 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/bad-results/months-bugs.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/amazing.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/amazing.png new file mode 100644 index 000000000..9b4475a73 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/amazing.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/better-code-docs-tests.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/better-code-docs-tests.png new file mode 100644 index 000000000..5f8b65947 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/better-code-docs-tests.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/higher-level.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/higher-level.png new file mode 100644 index 000000000..80b6b2e66 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/higher-level.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/really-super-powers.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/really-super-powers.png new file mode 100644 index 000000000..2d0758617 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/really-super-powers.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/super-power.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/super-power.png new file mode 100644 index 000000000..16b4a0e12 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/super-power.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/test-coverage.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/test-coverage.png new file mode 100644 index 000000000..963d892a1 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/better-software/test-coverage.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/calculator.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/calculator.png new file mode 100644 index 000000000..1032498fd Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/calculator.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/cheating-math.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/cheating-math.png new file mode 100644 index 000000000..820fbf558 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/cheating-math.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/corner-drag.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/corner-drag.png new file mode 100644 index 000000000..957ec96a2 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/corner-drag.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/interns.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/interns.png new file mode 100644 index 000000000..c3115d716 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/interns.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/not-equally-good.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/not-equally-good.png new file mode 100644 index 000000000..af4603d7e Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/not-equally-good.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/pros-cons.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/pros-cons.png new file mode 100644 index 000000000..fe2c301ac Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/calculator/pros-cons.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/10-20-pct.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/10-20-pct.png new file mode 100644 index 000000000..76abd7ffc Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/10-20-pct.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/30-line-test.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/30-line-test.png new file mode 100644 index 000000000..2f0ff41ed Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/30-line-test.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/boring-stuff.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/boring-stuff.png new file mode 100644 index 000000000..6a7bd9455 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/boring-stuff.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/hours-to-minutes.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/hours-to-minutes.png new file mode 100644 index 000000000..9b6233cc1 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/hours-to-minutes.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/mundane.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/mundane.png new file mode 100644 index 000000000..525376610 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/mundane.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/near-perfect.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/near-perfect.png new file mode 100644 index 000000000..277e7f1d1 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/near-perfect.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/tedium.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/tedium.png new file mode 100644 index 000000000..3ca3a63db Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/tedium.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/twice-as-fast.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/twice-as-fast.png new file mode 100644 index 000000000..59e6bd278 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/twice-as-fast.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/worth-it.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/worth-it.png new file mode 100644 index 000000000..9e6d29c24 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/faster-software/worth-it.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/funny-angular.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/funny-angular.png new file mode 100644 index 000000000..a45405c1b Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/funny-angular.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/funny-chat.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/funny-chat.png new file mode 100644 index 000000000..9cc5d49dc Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/funny-chat.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/good-news/100m-arr.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/good-news/100m-arr.png new file mode 100644 index 000000000..2312cfe93 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/good-news/100m-arr.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/good-news/codium.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/good-news/codium.png new file mode 100644 index 000000000..9d9a41092 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/good-news/codium.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/good-news/cursor.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/good-news/cursor.png new file mode 100644 index 000000000..f8f34c9a3 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/good-news/cursor.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/good-news/tabby.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/good-news/tabby.png new file mode 100644 index 000000000..3e0542265 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/good-news/tabby.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/good-news/tabnine.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/good-news/tabnine.png new file mode 100644 index 000000000..fb0839c3f Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/good-news/tabnine.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/lawsuit.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/lawsuit.png new file mode 100644 index 000000000..115c5f52c Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/lawsuit.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/caused-more-problems.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/caused-more-problems.png new file mode 100644 index 000000000..537bab710 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/caused-more-problems.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/hassle.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/hassle.png new file mode 100644 index 000000000..135990502 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/hassle.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/interferes.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/interferes.png new file mode 100644 index 000000000..0de675dce Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/interferes.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/junior-dev.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/junior-dev.png new file mode 100644 index 000000000..181c6b57d Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/junior-dev.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/screwed.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/screwed.png new file mode 100644 index 000000000..8fb74b55a Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/screwed.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/subtle-bugs.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/subtle-bugs.png new file mode 100644 index 000000000..a75519ad3 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/after/more-problems/subtle-bugs.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/90-percent.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/90-percent.png new file mode 100644 index 000000000..d32757b33 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/90-percent.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/clippy.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/clippy.png new file mode 100644 index 000000000..7b27fa3ab Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/clippy.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/decades.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/decades.png new file mode 100644 index 000000000..8d5b861a3 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/decades.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/disaster.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/disaster.png new file mode 100644 index 000000000..1a2540bfe Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/disaster.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/fall-short.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/fall-short.png new file mode 100644 index 000000000..71fba3cf4 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/fall-short.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/far-worse.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/far-worse.png new file mode 100644 index 000000000..1d36ac275 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/far-worse.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/incorrect.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/incorrect.png new file mode 100644 index 000000000..2a3b543f5 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/incorrect.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/job-worry.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/job-worry.png new file mode 100644 index 000000000..7a422d0bb Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/job-worry.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/lying.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/lying.png new file mode 100644 index 000000000..d202ebd0b Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/lying.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/months-bugs.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/months-bugs.png new file mode 100644 index 000000000..ec8b6d923 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/bad-results/months-bugs.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/amazing.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/amazing.png new file mode 100644 index 000000000..d4eb530f7 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/amazing.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/better-code-docs-tests.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/better-code-docs-tests.png new file mode 100644 index 000000000..7e5bdc6ee Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/better-code-docs-tests.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/higher-level.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/higher-level.png new file mode 100644 index 000000000..d79747595 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/higher-level.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/really-super-powers.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/really-super-powers.png new file mode 100644 index 000000000..5eba4e8fe Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/really-super-powers.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/super-power.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/super-power.png new file mode 100644 index 000000000..448a73f17 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/super-power.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/test-coverage.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/test-coverage.png new file mode 100644 index 000000000..bd671d345 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/better-software/test-coverage.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/calculator.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/calculator.png new file mode 100644 index 000000000..a18a2a493 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/calculator.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/cheating-math.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/cheating-math.png new file mode 100644 index 000000000..c1a99e373 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/cheating-math.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/corner-drag.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/corner-drag.png new file mode 100644 index 000000000..8ddfd70b7 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/corner-drag.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/interns.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/interns.png new file mode 100644 index 000000000..27378dbde Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/interns.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/not-equally-good.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/not-equally-good.png new file mode 100644 index 000000000..d15e10781 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/not-equally-good.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/pros-cons.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/pros-cons.png new file mode 100644 index 000000000..a2e5d72f1 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/calculator/pros-cons.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/10-20-pct.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/10-20-pct.png new file mode 100644 index 000000000..cd9fd6cad Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/10-20-pct.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/30-line-test.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/30-line-test.png new file mode 100644 index 000000000..94b4036e1 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/30-line-test.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/boring-stuff.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/boring-stuff.png new file mode 100644 index 000000000..669bfc559 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/boring-stuff.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/hours-to-minutes.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/hours-to-minutes.png new file mode 100644 index 000000000..f996b12d3 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/hours-to-minutes.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/mundane.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/mundane.png new file mode 100644 index 000000000..1b0ef0609 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/mundane.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/near-perfect.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/near-perfect.png new file mode 100644 index 000000000..419d95928 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/near-perfect.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/tedium.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/tedium.png new file mode 100644 index 000000000..380fcd711 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/tedium.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/twice-as-fast.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/twice-as-fast.png new file mode 100644 index 000000000..175e88645 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/twice-as-fast.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/worth-it.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/worth-it.png new file mode 100644 index 000000000..fa3531c58 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/faster-software/worth-it.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/funny-angular.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/funny-angular.png new file mode 100644 index 000000000..ac0c6a0f5 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/funny-angular.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/funny-chat.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/funny-chat.png new file mode 100644 index 000000000..09f8f55aa Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/funny-chat.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/good-news/100m-arr.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/good-news/100m-arr.png new file mode 100644 index 000000000..0a9df0ff7 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/good-news/100m-arr.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/good-news/codium.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/good-news/codium.png new file mode 100644 index 000000000..6e85e7b0b Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/good-news/codium.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/good-news/cursor.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/good-news/cursor.png new file mode 100644 index 000000000..8ca2e5bc8 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/good-news/cursor.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/good-news/tabby.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/good-news/tabby.png new file mode 100644 index 000000000..0fd21fad2 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/good-news/tabby.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/good-news/tabnine.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/good-news/tabnine.png new file mode 100644 index 000000000..7872153c3 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/good-news/tabnine.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/lawsuit.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/lawsuit.png new file mode 100644 index 000000000..584bf675c Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/lawsuit.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/caused-more-problems.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/caused-more-problems.png new file mode 100644 index 000000000..4b2906981 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/caused-more-problems.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/hassle.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/hassle.png new file mode 100644 index 000000000..b69d984d5 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/hassle.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/interferes.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/interferes.png new file mode 100644 index 000000000..feac890d9 Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/interferes.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/junior-dev.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/junior-dev.png new file mode 100644 index 000000000..5a69c5c3a Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/junior-dev.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/screwed.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/screwed.png new file mode 100644 index 000000000..f8bfe98fc Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/screwed.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/subtle-bugs.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/subtle-bugs.png new file mode 100644 index 000000000..150e7f14a Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/before/more-problems/subtle-bugs.png differ diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/crop.py b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/crop.py new file mode 100644 index 000000000..b44e0f44f --- /dev/null +++ b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/crop.py @@ -0,0 +1,102 @@ +import os +import cv2 +import numpy as np +from PIL import Image + +def find_content_bounds(image_path, buffer_pixels=5): + # Load the image using OpenCV + img = cv2.imread(image_path, cv2.IMREAD_GRAYSCALE) + + # Apply Canny edge detection + edges = cv2.Canny(img, threshold1=100, threshold2=200) + + # Find contours of the content + contours, _ = cv2.findContours(edges, cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_SIMPLE) + + if contours: + # Find the bounding rectangle of the largest contour + largest_contour = max(contours, key=cv2.contourArea) + x, y, w, h = cv2.boundingRect(largest_contour) + + # Add buffer to the detected content region + x -= buffer_pixels + y -= buffer_pixels + w += 2 * buffer_pixels + h += 2 * buffer_pixels + + # Ensure the new region does not go outside the image bounds + x = max(0, x) + y = max(0, y) + w = min(img.shape[1], x + w) - x + h = min(img.shape[0], y + h) - y + + return x, y, x + w, y + h + + return None + +def crop_and_pad_center(image_path, output_path, padding): + # Find content bounds + content_bounds = find_content_bounds(image_path) + + if content_bounds: + # Open the image using Pillow + img = Image.open(image_path) + + # Check if the image has an alpha channel (transparency) + has_alpha = img.mode == 'RGBA' + + # Calculate cropping coordinates + left, upper, right, lower = content_bounds + + # Crop the content + cropped_img = img.crop((left, upper, right, lower)) + + # Calculate new dimensions for the padded image + new_width = cropped_img.width + 2 * padding + new_height = cropped_img.height + 2 * padding + + # Create a new image with padding + padded_img = Image.new('RGBA' if has_alpha else 'RGB', (new_width, new_height), (255, 255, 255, 0) if has_alpha else (255, 255, 255)) + padded_img.paste(cropped_img, (padding, padding)) + + # Save the result to the output path + padded_img.save(output_path) + else: + print("No content detected in", image_path) + + +def process_images_in_folder(input_folder, output_folder, padding): + # Create the output folder if it doesn't exist + if not os.path.exists(output_folder): + os.makedirs(output_folder) + + # Recursively get a list of all relative file files in the input folder + file_list = [] + for root, directories, files in os.walk(input_folder): + for filename in files: + # Skip hidden files + if not filename.startswith('.'): + # Get relative path to file + file_path = os.path.join(root, filename) + relative_file_path = os.path.relpath(file_path, input_folder) + file_list.append(relative_file_path) + + for relative_file_path in file_list: + # Check if the file is an image (you can modify the extensions if needed) + if relative_file_path.lower().endswith(('.png', '.jpg', '.jpeg', '.gif', '.bmp')): + # Get the input and output image paths + input_image_path = os.path.join(input_folder, relative_file_path) + output_image_path = os.path.join(output_folder, relative_file_path) + + # create any missing directores for the output_image_path + os.makedirs(os.path.dirname(output_image_path), exist_ok=True) + + # Crop and pad the image + crop_and_pad_center(input_image_path, output_image_path, padding) + +if __name__ == "__main__": + input_folder_path = "./before" # Specify the input folder path + output_folder_path = "./after" # Specify the output folder path + padding_amount = 20 # Specify the padding amount in pixels + + process_images_in_folder(input_folder_path, output_folder_path, padding_amount) diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/generate-carousel.py b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/generate-carousel.py new file mode 100644 index 000000000..5447c7975 --- /dev/null +++ b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/generate-carousel.py @@ -0,0 +1,59 @@ +import os +import pyperclip +from urllib.parse import urlparse + +def get_comment(file_path): + """Fetches the comment of a file on MacOS using AppleScript.""" + script = f''' + tell application "Finder" + set theItem to (POSIX file "{file_path}") as alias + get comment of theItem + end tell + ''' + return os.popen(f"osascript -e '{script}'").read().strip() + +def extract_source_website(url): + """Extracts the source website from a given URL.""" + netloc = urlparse(url).netloc + if "youtube" in netloc: + return "YouTube" + elif "news.ycombinator" in netloc: + return "Hacker News" + elif "twitter" in netloc: + return "Twitter" + elif "reddit" in netloc: + return "Reddit" + else: + # Return the domain name as default if no other conditions match + return netloc + +def generate_string(folder_path): + output_str = "" + for file_name in os.listdir(folder_path): + if file_name.endswith('.png'): + file_path = os.path.join(folder_path, file_name) + + comment = get_comment(file_path) + source_website = extract_source_website(comment) + + file_name_without_ext = os.path.splitext(file_name)[0] + folder_name = os.path.basename(os.path.normpath(folder_path)) # This gives 'bad-result' for './before/bad-result' + + slide = f""" + +
{source_website}}}> + ![{file_name_without_ext}](./github-copilot-assets/slides/after/{folder_name}/{file_name}) +
+
""" + output_str += slide + + output_str += "\n
" + return output_str + +folder_path = input("Enter the path of the folder containing the images (e.g. ./before/bad-result): ") +output = generate_string(folder_path) +print(output) + +# Copy the output to the clipboard +pyperclip.copy(output) +print("The generated string has been copied to the clipboard!") diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/poetry.lock b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/poetry.lock new file mode 100644 index 000000000..91f896c70 --- /dev/null +++ b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/poetry.lock @@ -0,0 +1,151 @@ +# This file is automatically @generated by Poetry 1.5.1 and should not be changed by hand. + +[[package]] +name = "numpy" +version = "1.26.1" +description = "Fundamental package for array computing in Python" +optional = false +python-versions = "<3.13,>=3.9" +files = [ + {file = "numpy-1.26.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:82e871307a6331b5f09efda3c22e03c095d957f04bf6bc1804f30048d0e5e7af"}, + {file = "numpy-1.26.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:cdd9ec98f0063d93baeb01aad472a1a0840dee302842a2746a7a8e92968f9575"}, + {file = "numpy-1.26.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d78f269e0c4fd365fc2992c00353e4530d274ba68f15e968d8bc3c69ce5f5244"}, + {file = "numpy-1.26.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8ab9163ca8aeb7fd32fe93866490654d2f7dda4e61bc6297bf72ce07fdc02f67"}, + {file = "numpy-1.26.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:78ca54b2f9daffa5f323f34cdf21e1d9779a54073f0018a3094ab907938331a2"}, + {file = "numpy-1.26.1-cp310-cp310-win32.whl", hash = "sha256:d1cfc92db6af1fd37a7bb58e55c8383b4aa1ba23d012bdbba26b4bcca45ac297"}, + {file = "numpy-1.26.1-cp310-cp310-win_amd64.whl", hash = "sha256:d2984cb6caaf05294b8466966627e80bf6c7afd273279077679cb010acb0e5ab"}, + {file = "numpy-1.26.1-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:cd7837b2b734ca72959a1caf3309457a318c934abef7a43a14bb984e574bbb9a"}, + {file = "numpy-1.26.1-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:1c59c046c31a43310ad0199d6299e59f57a289e22f0f36951ced1c9eac3665b9"}, + {file = "numpy-1.26.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d58e8c51a7cf43090d124d5073bc29ab2755822181fcad978b12e144e5e5a4b3"}, + {file = "numpy-1.26.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6081aed64714a18c72b168a9276095ef9155dd7888b9e74b5987808f0dd0a974"}, + {file = "numpy-1.26.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:97e5d6a9f0702c2863aaabf19f0d1b6c2628fbe476438ce0b5ce06e83085064c"}, + {file = "numpy-1.26.1-cp311-cp311-win32.whl", hash = "sha256:b9d45d1dbb9de84894cc50efece5b09939752a2d75aab3a8b0cef6f3a35ecd6b"}, + {file = "numpy-1.26.1-cp311-cp311-win_amd64.whl", hash = "sha256:3649d566e2fc067597125428db15d60eb42a4e0897fc48d28cb75dc2e0454e53"}, + {file = "numpy-1.26.1-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:1d1bd82d539607951cac963388534da3b7ea0e18b149a53cf883d8f699178c0f"}, + {file = "numpy-1.26.1-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:afd5ced4e5a96dac6725daeb5242a35494243f2239244fad10a90ce58b071d24"}, + {file = "numpy-1.26.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a03fb25610ef560a6201ff06df4f8105292ba56e7cdd196ea350d123fc32e24e"}, + {file = "numpy-1.26.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:dcfaf015b79d1f9f9c9fd0731a907407dc3e45769262d657d754c3a028586124"}, + {file = "numpy-1.26.1-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:e509cbc488c735b43b5ffea175235cec24bbc57b227ef1acc691725beb230d1c"}, + {file = "numpy-1.26.1-cp312-cp312-win32.whl", hash = "sha256:af22f3d8e228d84d1c0c44c1fbdeb80f97a15a0abe4f080960393a00db733b66"}, + {file = "numpy-1.26.1-cp312-cp312-win_amd64.whl", hash = "sha256:9f42284ebf91bdf32fafac29d29d4c07e5e9d1af862ea73686581773ef9e73a7"}, + {file = "numpy-1.26.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:bb894accfd16b867d8643fc2ba6c8617c78ba2828051e9a69511644ce86ce83e"}, + {file = "numpy-1.26.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:e44ccb93f30c75dfc0c3aa3ce38f33486a75ec9abadabd4e59f114994a9c4617"}, + {file = "numpy-1.26.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9696aa2e35cc41e398a6d42d147cf326f8f9d81befcb399bc1ed7ffea339b64e"}, + {file = "numpy-1.26.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a5b411040beead47a228bde3b2241100454a6abde9df139ed087bd73fc0a4908"}, + {file = "numpy-1.26.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:1e11668d6f756ca5ef534b5be8653d16c5352cbb210a5c2a79ff288e937010d5"}, + {file = "numpy-1.26.1-cp39-cp39-win32.whl", hash = "sha256:d1d2c6b7dd618c41e202c59c1413ef9b2c8e8a15f5039e344af64195459e3104"}, + {file = "numpy-1.26.1-cp39-cp39-win_amd64.whl", hash = "sha256:59227c981d43425ca5e5c01094d59eb14e8772ce6975d4b2fc1e106a833d5ae2"}, + {file = "numpy-1.26.1-pp39-pypy39_pp73-macosx_10_9_x86_64.whl", hash = "sha256:06934e1a22c54636a059215d6da99e23286424f316fddd979f5071093b648668"}, + {file = "numpy-1.26.1-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:76ff661a867d9272cd2a99eed002470f46dbe0943a5ffd140f49be84f68ffc42"}, + {file = "numpy-1.26.1-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:6965888d65d2848e8768824ca8288db0a81263c1efccec881cb35a0d805fcd2f"}, + {file = "numpy-1.26.1.tar.gz", hash = "sha256:c8c6c72d4a9f831f328efb1312642a1cafafaa88981d9ab76368d50d07d93cbe"}, +] + +[[package]] +name = "opencv-python" +version = "4.8.1.78" +description = "Wrapper package for OpenCV python bindings." +optional = false +python-versions = ">=3.6" +files = [ + {file = "opencv-python-4.8.1.78.tar.gz", hash = "sha256:cc7adbbcd1112877a39274106cb2752e04984bc01a031162952e97450d6117f6"}, + {file = "opencv_python-4.8.1.78-cp37-abi3-macosx_10_16_x86_64.whl", hash = "sha256:91d5f6f5209dc2635d496f6b8ca6573ecdad051a09e6b5de4c399b8e673c60da"}, + {file = "opencv_python-4.8.1.78-cp37-abi3-macosx_11_0_arm64.whl", hash = "sha256:bc31f47e05447da8b3089faa0a07ffe80e114c91ce0b171e6424f9badbd1c5cd"}, + {file = "opencv_python-4.8.1.78-cp37-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9814beca408d3a0eca1bae7e3e5be68b07c17ecceb392b94170881216e09b319"}, + {file = "opencv_python-4.8.1.78-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:c4c406bdb41eb21ea51b4e90dfbc989c002786c3f601c236a99c59a54670a394"}, + {file = "opencv_python-4.8.1.78-cp37-abi3-win32.whl", hash = "sha256:a7aac3900fbacf55b551e7b53626c3dad4c71ce85643645c43e91fcb19045e47"}, + {file = "opencv_python-4.8.1.78-cp37-abi3-win_amd64.whl", hash = "sha256:b983197f97cfa6fcb74e1da1802c7497a6f94ed561aba6980f1f33123f904956"}, +] + +[package.dependencies] +numpy = [ + {version = ">=1.21.0", markers = "python_version <= \"3.9\" and platform_system == \"Darwin\" and platform_machine == \"arm64\""}, + {version = ">=1.21.2", markers = "python_version >= \"3.10\""}, + {version = ">=1.21.4", markers = "python_version >= \"3.10\" and platform_system == \"Darwin\""}, + {version = ">=1.23.5", markers = "python_version >= \"3.11\""}, + {version = ">=1.19.3", markers = "python_version >= \"3.6\" and platform_system == \"Linux\" and platform_machine == \"aarch64\" or python_version >= \"3.9\""}, + {version = ">=1.17.0", markers = "python_version >= \"3.7\""}, + {version = ">=1.17.3", markers = "python_version >= \"3.8\""}, +] + +[[package]] +name = "pillow" +version = "10.1.0" +description = "Python Imaging Library (Fork)" +optional = false +python-versions = ">=3.8" +files = [ + {file = "Pillow-10.1.0-cp310-cp310-macosx_10_10_x86_64.whl", hash = "sha256:1ab05f3db77e98f93964697c8efc49c7954b08dd61cff526b7f2531a22410106"}, + {file = "Pillow-10.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:6932a7652464746fcb484f7fc3618e6503d2066d853f68a4bd97193a3996e273"}, + {file = "Pillow-10.1.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a5f63b5a68daedc54c7c3464508d8c12075e56dcfbd42f8c1bf40169061ae666"}, + {file = "Pillow-10.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:c0949b55eb607898e28eaccb525ab104b2d86542a85c74baf3a6dc24002edec2"}, + {file = "Pillow-10.1.0-cp310-cp310-manylinux_2_28_aarch64.whl", hash = "sha256:ae88931f93214777c7a3aa0a8f92a683f83ecde27f65a45f95f22d289a69e593"}, + {file = "Pillow-10.1.0-cp310-cp310-manylinux_2_28_x86_64.whl", hash = "sha256:b0eb01ca85b2361b09480784a7931fc648ed8b7836f01fb9241141b968feb1db"}, + {file = "Pillow-10.1.0-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:d27b5997bdd2eb9fb199982bb7eb6164db0426904020dc38c10203187ae2ff2f"}, + {file = "Pillow-10.1.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:7df5608bc38bd37ef585ae9c38c9cd46d7c81498f086915b0f97255ea60c2818"}, + {file = "Pillow-10.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:41f67248d92a5e0a2076d3517d8d4b1e41a97e2df10eb8f93106c89107f38b57"}, + {file = "Pillow-10.1.0-cp311-cp311-macosx_10_10_x86_64.whl", hash = "sha256:1fb29c07478e6c06a46b867e43b0bcdb241b44cc52be9bc25ce5944eed4648e7"}, + {file = "Pillow-10.1.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:2cdc65a46e74514ce742c2013cd4a2d12e8553e3a2563c64879f7c7e4d28bce7"}, + {file = "Pillow-10.1.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50d08cd0a2ecd2a8657bd3d82c71efd5a58edb04d9308185d66c3a5a5bed9610"}, + {file = "Pillow-10.1.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:062a1610e3bc258bff2328ec43f34244fcec972ee0717200cb1425214fe5b839"}, + {file = "Pillow-10.1.0-cp311-cp311-manylinux_2_28_aarch64.whl", hash = "sha256:61f1a9d247317fa08a308daaa8ee7b3f760ab1809ca2da14ecc88ae4257d6172"}, + {file = "Pillow-10.1.0-cp311-cp311-manylinux_2_28_x86_64.whl", hash = "sha256:a646e48de237d860c36e0db37ecaecaa3619e6f3e9d5319e527ccbc8151df061"}, + {file = "Pillow-10.1.0-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:47e5bf85b80abc03be7455c95b6d6e4896a62f6541c1f2ce77a7d2bb832af262"}, + {file = "Pillow-10.1.0-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:a92386125e9ee90381c3369f57a2a50fa9e6aa8b1cf1d9c4b200d41a7dd8e992"}, + {file = "Pillow-10.1.0-cp311-cp311-win_amd64.whl", hash = "sha256:0f7c276c05a9767e877a0b4c5050c8bee6a6d960d7f0c11ebda6b99746068c2a"}, + {file = "Pillow-10.1.0-cp312-cp312-macosx_10_10_x86_64.whl", hash = "sha256:a89b8312d51715b510a4fe9fc13686283f376cfd5abca8cd1c65e4c76e21081b"}, + {file = "Pillow-10.1.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:00f438bb841382b15d7deb9a05cc946ee0f2c352653c7aa659e75e592f6fa17d"}, + {file = "Pillow-10.1.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3d929a19f5469b3f4df33a3df2983db070ebb2088a1e145e18facbc28cae5b27"}, + {file = "Pillow-10.1.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9a92109192b360634a4489c0c756364c0c3a2992906752165ecb50544c251312"}, + {file = "Pillow-10.1.0-cp312-cp312-manylinux_2_28_aarch64.whl", hash = "sha256:0248f86b3ea061e67817c47ecbe82c23f9dd5d5226200eb9090b3873d3ca32de"}, + {file = "Pillow-10.1.0-cp312-cp312-manylinux_2_28_x86_64.whl", hash = "sha256:9882a7451c680c12f232a422730f986a1fcd808da0fd428f08b671237237d651"}, + {file = "Pillow-10.1.0-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:1c3ac5423c8c1da5928aa12c6e258921956757d976405e9467c5f39d1d577a4b"}, + {file = "Pillow-10.1.0-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:806abdd8249ba3953c33742506fe414880bad78ac25cc9a9b1c6ae97bedd573f"}, + {file = "Pillow-10.1.0-cp312-cp312-win_amd64.whl", hash = "sha256:eaed6977fa73408b7b8a24e8b14e59e1668cfc0f4c40193ea7ced8e210adf996"}, + {file = "Pillow-10.1.0-cp38-cp38-macosx_10_10_x86_64.whl", hash = "sha256:fe1e26e1ffc38be097f0ba1d0d07fcade2bcfd1d023cda5b29935ae8052bd793"}, + {file = "Pillow-10.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:7a7e3daa202beb61821c06d2517428e8e7c1aab08943e92ec9e5755c2fc9ba5e"}, + {file = "Pillow-10.1.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:24fadc71218ad2b8ffe437b54876c9382b4a29e030a05a9879f615091f42ffc2"}, + {file = "Pillow-10.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:fa1d323703cfdac2036af05191b969b910d8f115cf53093125e4058f62012c9a"}, + {file = "Pillow-10.1.0-cp38-cp38-manylinux_2_28_aarch64.whl", hash = "sha256:912e3812a1dbbc834da2b32299b124b5ddcb664ed354916fd1ed6f193f0e2d01"}, + {file = "Pillow-10.1.0-cp38-cp38-manylinux_2_28_x86_64.whl", hash = "sha256:7dbaa3c7de82ef37e7708521be41db5565004258ca76945ad74a8e998c30af8d"}, + {file = "Pillow-10.1.0-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:9d7bc666bd8c5a4225e7ac71f2f9d12466ec555e89092728ea0f5c0c2422ea80"}, + {file = "Pillow-10.1.0-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:baada14941c83079bf84c037e2d8b7506ce201e92e3d2fa0d1303507a8538212"}, + {file = "Pillow-10.1.0-cp38-cp38-win_amd64.whl", hash = "sha256:2ef6721c97894a7aa77723740a09547197533146fba8355e86d6d9a4a1056b14"}, + {file = "Pillow-10.1.0-cp39-cp39-macosx_10_10_x86_64.whl", hash = "sha256:0a026c188be3b443916179f5d04548092e253beb0c3e2ee0a4e2cdad72f66099"}, + {file = "Pillow-10.1.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:04f6f6149f266a100374ca3cc368b67fb27c4af9f1cc8cb6306d849dcdf12616"}, + {file = "Pillow-10.1.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:bb40c011447712d2e19cc261c82655f75f32cb724788df315ed992a4d65696bb"}, + {file = "Pillow-10.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1a8413794b4ad9719346cd9306118450b7b00d9a15846451549314a58ac42219"}, + {file = "Pillow-10.1.0-cp39-cp39-manylinux_2_28_aarch64.whl", hash = "sha256:c9aeea7b63edb7884b031a35305629a7593272b54f429a9869a4f63a1bf04c34"}, + {file = "Pillow-10.1.0-cp39-cp39-manylinux_2_28_x86_64.whl", hash = "sha256:b4005fee46ed9be0b8fb42be0c20e79411533d1fd58edabebc0dd24626882cfd"}, + {file = "Pillow-10.1.0-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:4d0152565c6aa6ebbfb1e5d8624140a440f2b99bf7afaafbdbf6430426497f28"}, + {file = "Pillow-10.1.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:d921bc90b1defa55c9917ca6b6b71430e4286fc9e44c55ead78ca1a9f9eba5f2"}, + {file = "Pillow-10.1.0-cp39-cp39-win_amd64.whl", hash = "sha256:cfe96560c6ce2f4c07d6647af2d0f3c54cc33289894ebd88cfbb3bcd5391e256"}, + {file = "Pillow-10.1.0-pp310-pypy310_pp73-macosx_10_10_x86_64.whl", hash = "sha256:937bdc5a7f5343d1c97dc98149a0be7eb9704e937fe3dc7140e229ae4fc572a7"}, + {file = "Pillow-10.1.0-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b1c25762197144e211efb5f4e8ad656f36c8d214d390585d1d21281f46d556ba"}, + {file = "Pillow-10.1.0-pp310-pypy310_pp73-manylinux_2_28_x86_64.whl", hash = "sha256:afc8eef765d948543a4775f00b7b8c079b3321d6b675dde0d02afa2ee23000b4"}, + {file = "Pillow-10.1.0-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:883f216eac8712b83a63f41b76ddfb7b2afab1b74abbb413c5df6680f071a6b9"}, + {file = "Pillow-10.1.0-pp39-pypy39_pp73-macosx_10_10_x86_64.whl", hash = "sha256:b920e4d028f6442bea9a75b7491c063f0b9a3972520731ed26c83e254302eb1e"}, + {file = "Pillow-10.1.0-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1c41d960babf951e01a49c9746f92c5a7e0d939d1652d7ba30f6b3090f27e412"}, + {file = "Pillow-10.1.0-pp39-pypy39_pp73-manylinux_2_28_x86_64.whl", hash = "sha256:1fafabe50a6977ac70dfe829b2d5735fd54e190ab55259ec8aea4aaea412fa0b"}, + {file = "Pillow-10.1.0-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:3b834f4b16173e5b92ab6566f0473bfb09f939ba14b23b8da1f54fa63e4b623f"}, + {file = "Pillow-10.1.0.tar.gz", hash = "sha256:e6bf8de6c36ed96c86ea3b6e1d5273c53f46ef518a062464cd7ef5dd2cf92e38"}, +] + +[package.extras] +docs = ["furo", "olefile", "sphinx (>=2.4)", "sphinx-copybutton", "sphinx-inline-tabs", "sphinx-removed-in", "sphinxext-opengraph"] +tests = ["check-manifest", "coverage", "defusedxml", "markdown2", "olefile", "packaging", "pyroma", "pytest", "pytest-cov", "pytest-timeout"] + +[[package]] +name = "pyperclip" +version = "1.8.2" +description = "A cross-platform clipboard module for Python. (Only handles plain text for now.)" +optional = false +python-versions = "*" +files = [ + {file = "pyperclip-1.8.2.tar.gz", hash = "sha256:105254a8b04934f0bc84e9c24eb360a591aaf6535c9def5f29d92af107a9bf57"}, +] + +[metadata] +lock-version = "2.0" +python-versions = "<3.13,>=3.9" +content-hash = "2218defa1ce463ad49bc039ed911718f073822248ece4fc1023bcb3f5a0942fc" diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/pyproject.toml b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/pyproject.toml new file mode 100644 index 000000000..894d07441 --- /dev/null +++ b/generator/konfig-docs/blog/2023/10/github-copilot-assets/slides/pyproject.toml @@ -0,0 +1,19 @@ +[tool.poetry] +name = "slides" +version = "0.1.0" +description = "" +authors = ["konfig-bot "] +readme = "README.md" + +[tool.poetry.dependencies] +python = "<3.13,>=3.9" +opencv-python = "^4.8.1.78" +pyperclip = "^1.8.2" + +[tool.poetry.group.dev.dependencies] +numpy = "^1.26.1" +Pillow = "^10.1.0" + +[build-system] +requires = ["poetry-core"] +build-backend = "poetry.core.masonry.api" diff --git a/generator/konfig-docs/blog/2023/10/github-copilot-assets/whiteboard.png b/generator/konfig-docs/blog/2023/10/github-copilot-assets/whiteboard.png new file mode 100644 index 000000000..3e7bf54ce Binary files /dev/null and b/generator/konfig-docs/blog/2023/10/github-copilot-assets/whiteboard.png differ diff --git a/generator/konfig-docs/blog/authors.yml b/generator/konfig-docs/blog/authors.yml index 0c388aa51..6cc63e9e0 100644 --- a/generator/konfig-docs/blog/authors.yml +++ b/generator/konfig-docs/blog/authors.yml @@ -2,7 +2,7 @@ dylan: name: Dylan Huang title: Co-Founder at Konfig bio: | - Dylan built SDK & API tooling at C3.ai. Dylan is also an avid builder and once built a viral website with over 210,000 unique users. + Dylan is a Co-Founder at Konfig. Previously, he built SDK & API tooling at C3.ai. He also once built a viral website with over 210,000 unique users. url: https://github.com/dphuang2 github: https://github.com/dphuang2 linkedin: https://www.linkedin.com/in/dphuang2/ diff --git a/generator/konfig-docs/sidebars.js b/generator/konfig-docs/sidebars.js index 86fdcdd47..8f383e2bf 100644 --- a/generator/konfig-docs/sidebars.js +++ b/generator/konfig-docs/sidebars.js @@ -88,7 +88,7 @@ const sidebars = { ], }, { - label: "Documentation", + label: "Docs", type: "category", collapsible: false, items: [ diff --git a/generator/konfig-docs/src/css/custom.css b/generator/konfig-docs/src/css/custom.css index 64b1ef272..4b4d5befd 100644 --- a/generator/konfig-docs/src/css/custom.css +++ b/generator/konfig-docs/src/css/custom.css @@ -38,16 +38,11 @@ figure { --ifm-font-size-base: 16px; --ifm-menu-link-padding-vertical: 0.5rem; --ifm-menu-color: var(--ifm-color-gray-600); - --ifm-link-hover-decoration: none; - --ifm-link-decoration: none; --ifm-menu-color-background-active: var( --ifm-color-primary-contrast-background ); -} - -.alert { - --ifm-link-hover-decoration: none; - --ifm-link-decoration: none; + --ifm-breadcrumb-border-radius: 0.5rem; + --ifm-toc-border-color: var(--ifm-color-emphasis-100); } .markdown { @@ -62,16 +57,24 @@ figure { } .markdown a { - color: var(--ifm-color-emphasis-1000); - border-bottom: 1px solid var(--ifm-color-primary-light); + color: var(--ifm-color-primary); + font-weight: 600; } .markdown p { margin-top: 1rem; } -.markdown a:hover { - border-bottom-width: 2px; +.markdown h1:first-child { + --ifm-h1-font-size: 2rem !important; + + margin-bottom: calc( + var(--ifm-h1-vertical-rhythm-bottom) * var(--ifm-leading) + ); +} + +.markdown img { + border-radius: var(--ifm-global-radius); } .markdown h1, @@ -91,6 +94,7 @@ h6 { --ifm-color-primary-light: #024498; --ifm-color-primary-lighter: #02479f; --ifm-color-primary-lightest: #0351b3; + --ifm-alert-border-radius: 0; } [data-theme="dark"] { @@ -110,6 +114,12 @@ swiper-container { swiper-slide { margin-top: auto; margin-bottom: auto; + text-align: center; +} + +swiper-slide img { + max-height: 450px; + width: auto; } :root { @@ -240,6 +250,7 @@ summary { .menu__link { line-height: 1.55; + border-radius: 0.5rem; } .navbar { @@ -247,6 +258,11 @@ summary { box-shadow: none !important; } +.navbar-sidebar__brand { + border-bottom: 1px solid var(--ifm-toc-border-color); + box-shadow: none !important; +} + .menu__link--sublist-caret:after { background: var(--ifm-menu-link-sublist-icon) 50% / 1rem 1rem; } @@ -267,22 +283,84 @@ summary { background: var(--ifm-menu-link-sublist-icon) 50% / 1rem 1rem; } +.navbar { + padding-top: 0; + padding-bottom: 0; +} + +@media (min-width: 996px) { + .navbar__item { + display: flex; + align-items: center; + height: 100%; + } +} + .navbar__link { color: var(--ifm-color-gray-600); + font-size: 0.875rem; + font-weight: var(--ifm-font-weight-bold); } .navbar__link--active { + margin-top: 2px; color: var(--ifm-color-primary); + border-bottom: 2px solid var(--ifm-color-primary); } -.menu__list-item:not(:first-child) { - margin-top: 0; +.navbar__link:hover { + color: var(--ifm-color-primary); } -.navbar__link:hover { - color: var(--ifm-color-emphasis-800); +.menu__list-item:not(:first-child) { + margin-top: 0; } .menu__list .menu__list { margin-top: 0; } + +.avatar__subtitle { + color: var(--ifm-color-gray-700); +} + +.breadcrumbs { + margin-left: calc( + var(--ifm-breadcrumb-padding-horizontal) * + var(--ifm-breadcrumb-size-multiplier) * -1 + ); +} + +.breadcrumbs__link { + color: var(--ifm-color-primary); + font-weight: var(--ifm-font-weight-bold); + font-size: 0.875rem; +} + +.breadcrumbs__item--active .breadcrumbs__link { + background: none; +} + +.breadcrumbs__link:any-link:hover { + background: var(--ifm-color-primary-contrast-background); +} + +.table-of-contents, +.table-of-contents ul { + padding-left: 0; +} + +.table-of-contents__link { + padding: 0.1rem 0.4rem; + color: var(--ifm-color-emphasis-600); +} + +.table-of-contents__link--active { + color: var(--ifm-color-primary); + bacgrkound: var(--ifm-color-primary-contrast-background); +} + +.ch-codegroup, +.ch-codeblock { + box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1); +} diff --git a/generator/konfig-docs/src/pages/interactive-tutorial/index.tsx b/generator/konfig-docs/src/pages/interactive-tutorial/index.tsx index 009bd6675..041271fbd 100644 --- a/generator/konfig-docs/src/pages/interactive-tutorial/index.tsx +++ b/generator/konfig-docs/src/pages/interactive-tutorial/index.tsx @@ -256,7 +256,7 @@ export default function LiveDemo({ sales }: { sales?: boolean }) { title={sales ? "Sales Demo" : "Interactive Tutorial"} description="Generate SDKs for your REST API with Konfig" > -
+
{name}
-
- {name} +
+ {name} {github && ( - + GitHub )} {linkedin && ( - + LinkedIn )}
-

{bio}

+

{bio}

); diff --git a/generator/konfig-docs/src/theme/BlogSidebar/Desktop/index.js b/generator/konfig-docs/src/theme/BlogSidebar/Desktop/index.js index 06682800c..b2382aeec 100644 --- a/generator/konfig-docs/src/theme/BlogSidebar/Desktop/index.js +++ b/generator/konfig-docs/src/theme/BlogSidebar/Desktop/index.js @@ -1,13 +1,31 @@ -import React from "react"; +import React, { useCallback, useLayoutEffect, useRef } from "react"; import clsx from "clsx"; import Link from "@docusaurus/Link"; import { translate } from "@docusaurus/Translate"; import styles from "./styles.module.css"; + export default function BlogSidebarDesktop({ sidebar }) { + const ref = useRef(null); + + const saveScrollPosition = useCallback(() => { + if (ref.current === null) return; + localStorage.setItem("blog-sidebar-scroll", ref.current.scrollTop); + }, []); + + useLayoutEffect(() => { + if (ref.current === null) return; + let top = localStorage.getItem("blog-sidebar-scroll"); + if (top === null) return; + ref.current.scrollTop = parseFloat(top); + }, []); + return (