Skip to content

Commit

Permalink
updates
Browse files Browse the repository at this point in the history
  • Loading branch information
jeffreyaven committed Sep 26, 2024
1 parent dbffa58 commit a2da7de
Show file tree
Hide file tree
Showing 3 changed files with 73 additions and 0 deletions.
17 changes: 17 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
## Description

Please include a summary of the changes and the related issue(s). Please also include relevant motivation and context.

Fixes #

## Checklist

Please make sure that the following criteria are met:

- [ ] The PR title is descriptive.
- [ ] Include documentation for example queries (comments or markdown in notebooks)
- [ ] I have ⭐'ed the [stackql](https://github.com/stackql/stackql) and [stackql-jupyter-demo](https://github.com/stackql/stackql-jupyter-demo) repos.

## Additional Notes

Add any additional information or context that might help the reviewers.
45 changes: 45 additions & 0 deletions .github/workflows/star-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: Check if PR author has starred the repository
on:
pull_request:
types: [opened, synchronize, reopened]

jobs:
check-starred:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/[email protected]

- name: Get PR author username
id: get-author
run: echo "username=${{ github.event.pull_request.user.login }}" >> $GITHUB_ENV

- name: Pull github provider
uses: stackql/[email protected]
with:
is_command: 'true'
query: "REGISTRY PULL github;"

- name: Run stackql query
id: check-star
uses: stackql/[email protected]
with:
test_query: |
SELECT repo, count(*) as has_starred
FROM github.activity.repo_stargazers
WHERE owner = 'stackql' and repo in ('stackql', 'stackql-jupyter-demo') and login = '${{ env.username }}'
GROUP BY repo;
expected_results_str: '[{"has_starred":"1","repo":"stackql"},{"has_starred":"1","repo":"stackql-jupyter-demo"}]'
continue-on-error: true

- name: Check if starred
if: always() # Ensures this runs regardless of check-star outcome
run: |
if [ "${{ steps.check-star.outcome }}" = "success" ]; then
echo "::notice::Thanks for your support!"
else
echo "::error::It seems you haven't starred the StackQL repositories. Please star the following repos before proceeding: https://github.com/stackql/stackql-jupyter-demo (this repo) and https://github.com/stackql/stackql (our core repo)"
exit 1
fi
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,14 @@
> **Calling All Cloud/Data/Security Enthusiasts, Hacktoberfest 2024 is here!**
> Interested in contributing StackQL (SQL) queries, notebooks and visualizations for **Cloud Security Posture Management (CSPM)**, **FinOps**, **Cloud Inventory Analysis**, or **Infrastructure-as-Code (IaC)**?
>
> Check out the issues and get started with your first pull request!, Let’s build something amazing together this Hacktoberfest!
💡 **Explore our repositories:** [StackQL](https://github.com/stackql/stackql), [StackQL Deploy](https://stackql-deploy.io/docs/), find provider documentation in the [StackQL Provider Registry Docs](https://registry.stackql.io/)

🔎 Build out example queries for [`aws`](https://aws.stackql.io/providers/aws/), [`gcp`](https://google.stackql.io/providers/google/), [`azure`](https://azure.stackql.io/providers/azure/), [`digitalocean`](https://digitalocean.stackql.io/providers/digitalocean/), [`linode`](https://linode.stackql.io/providers/linode/), [`okta`](https://okta.stackql.io/providers/okta/) and more, including multicloud queries!

---

[![StackQL](https://stackql.io/img/stackql-logo-bold.png)](https://stackql.io/)
<br />
[![GitHub Actions](https://github.com/stackql/stackql-jupyter-demo/actions/workflows/main.yml/badge.svg?branch=main)](https://github.com/stackql/stackql-jupyter-demo/actions/workflows/main.yml)
Expand Down

0 comments on commit a2da7de

Please sign in to comment.