Skip to content

Commit

Permalink
O vs (#28)
Browse files Browse the repository at this point in the history
## Summary by Sourcery

CI:
- Update the OSV-Scanner GitHub Actions workflow to improve readability
and maintainability by adding comments and reformatting the YAML
structure.
  • Loading branch information
CrzyHAX91 authored Dec 17, 2024
2 parents e44e668 + 30f9e00 commit ec0bb31
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 66 deletions.
53 changes: 40 additions & 13 deletions .github/workflows/osv-scanner.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,43 @@
# This workflow uses actions that are not certified by GitHub.
name: OSV-Scanner
name: OSV-Scanner Workflow

on:
pull_request: { branches: [ "main" ] }
merge_group: { branches: [ "main" ] }
schedule: [ { cron: '38 6 * * 6' } ]
push: { branches: [ "main" ] }
permissions: { security-events: write, contents: read }
jobs: { scan-scheduled: { if: ${{ github.event_name == 'push' || github.event_name == 'schedule' }}, uses: "google/osv-scanner-action/.github/workflows/osv-scanner-reusable.yml@1f1242919d8a60496dd1874b24b62b2370ed4c78", with: { scan-args: |-
# Triggers the workflow for pull requests to the main branch
pull_request:
branches:
- main
# Triggers for merge groups targeting the main branch
merge_group:
branches:
- main
# Scheduled scan every Saturday at 06:38 UTC
schedule:
- cron: '38 6 * * 6'
# Triggers for pushes to the main branch
push:
branches:
- main

permissions:
security-events: write
contents: read

jobs:
# Scheduled and push scans
scan-scheduled:
if: ${{ github.event_name == 'push' || github.event_name == 'schedule' }}
uses: google/osv-scanner-action/.github/workflows/osv-scanner-reusable.yml@v1
with:
scan-args: |
-r
--skip-git
./ } }, scan-pr: { if: ${{ github.event_name == 'pull_request' || github.event_name == 'merge_group' }}, uses: "google/osv-scanner-action/.github/workflows/osv-scanner-reusable-pr.yml@1f1242919d8a60496dd1874b24b62b2370ed4c78", with: { scan-args: |-
-r
--skip-git
./
} } }
./
# Pull request and merge group scans
scan-pr:
if: ${{ github.event_name == 'pull_request' || github.event_name == 'merge_group' }}
uses: google/osv-scanner-action/.github/workflows/osv-scanner-reusable-pr.yml@v1
with:
scan-args: |
-r
--skip-git
./
59 changes: 6 additions & 53 deletions new_dashboard_ui.patch
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
diff --git a/home/user/static/js/components/dashboard-layout.tsx b/home/user/static/js/components/dashboard-layout.tsx
diff --git a/home/user/static/js/components/dashboard-layout.tsx b/home/user/static/js/compononent/dashboard-layout.tsx
new file mode 100644
index 0000000..f114f4e
--- /dev/null

+++ b/home/user/static/js/components/dashboard-layout.tsx
@@ -0,0 +1,72 @@
+
Expand Down Expand Up @@ -79,7 +79,6 @@ index 0000000..f114f4e
diff --git a/home/user/static/js/components/sidebar-nav.tsx b/home/user/static/js/components/sidebar-nav.tsx
new file mode 100644
index 0000000..3412126
--- /dev/null
+++ b/home/user/static/js/components/sidebar-nav.tsx
@@ -0,0 +1,30 @@
+
Expand Down Expand Up @@ -192,19 +191,17 @@ index 0000000..538c176
+}
diff --git a/home/user/templates/base.html b/home/user/templates/base.html
index 4b164a1..289e8b5 100644
--- a/home/user/templates/base.html

+++ b/home/user/templates/base.html
@@ -1,67 +1,23 @@

-{% load static %}

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
- <title>{% block title %}Dropship Project{% endblock %}</title>
- <link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet">
- <link href="{% static 'css/custom.css' %}" rel="stylesheet">

+ <title>{% block title %}Dropship V2{% endblock %}</title>
+ <script src="https://cdn.tailwindcss.com"></script>
+ <style>
Expand All @@ -214,51 +211,7 @@ index 4b164a1..289e8b5 100644
+ }
+ </style>
+ {% block extra_head %}{% endblock %}
</head>
-<body>
- <nav class="navbar navbar-expand-lg navbar-light bg-light">
- <div class="container">
- <a class="navbar-brand" href="{% url 'home' %}">Dropship Project</a>
- <button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
- <span class="navbar-toggler-icon"></span>
- </button>
- <div class="collapse navbar-collapse" id="navbarNav">
- <ul class="navbar-nav">
- <li class="nav-item">
- <a class="nav-link" href="{% url 'home' %}">Home</a>
- </li>
- {% if user.is_authenticated %}
- <li class="nav-item">
- <a class="nav-link" href="{% url 'user_profile' %}">Profile</a>
- </li>
- <li class="nav-item">
- <a class="nav-link" href="{% url 'logout' %}">Logout</a>
- </li>
- {% else %}
- <li class="nav-item">
- <a class="nav-link" href="{% url 'login' %}">Login</a>
- </li>
- <li class="nav-item">
- <a class="nav-link" href="{% url 'register' %}">Register</a>
- </li>
- {% endif %}
- </ul>
- </div>
- </div>
- </nav>
-
- <div class="container mt-4">
- {% if messages %}
- {% for message in messages %}
- <div class="alert alert-{{ message.tags }} alert-dismissible fade show" role="alert">
- {{ message }}
- <button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close"></button>
- </div>
- {% endfor %}
- {% endif %}
-
- {% block content %}
- {% endblock %}
<
+<body class="bg-gray-100 dark:bg-gray-900">
+ <div id="app">
+ {% block content %}{% endblock %}
Expand Down

0 comments on commit ec0bb31

Please sign in to comment.