Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
Emil Sayahi committed Nov 30, 2020
0 parents commit 7146c16
Showing 27 changed files with 2,086 additions and 0 deletions.
38 changes: 38 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
---
name: Bug report
about: Create a report to help us improve
title: "[BUG] - "
labels: bug
assignees: ''

---

**Describe the bug**
A clear and concise description of what the bug is.

**To Reproduce**
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

**Expected behavior**
A clear and concise description of what you expected to happen.

**Screenshots**
If applicable, add screenshots to help explain your problem.

**Desktop (please complete the following information):**
- OS: [e.g. iOS]
- Browser [e.g. chrome, safari]
- Version [e.g. 22]

**Smartphone (please complete the following information):**
- Device: [e.g. iPhone6]
- OS: [e.g. iOS8.1]
- Browser [e.g. stock browser, safari]
- Version [e.g. 22]

**Additional context**
Add any other context about the problem here.
20 changes: 20 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
name: Feature request
about: Suggest an idea for this project
title: "[REQUEST] - "
labels: enhancement
assignees: ''

---

**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

**Describe the solution you'd like**
A clear and concise description of what you want to happen.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Additional context**
Add any other context or screenshots about the feature request here.
11 changes: 11 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# To get started with Dependabot version updates, you'll need to specify which
# package ecosystems to update and where the package manifests are located.
# Please see the documentation for all configuration options:
# https://help.github.com/github/administering-a-repository/configuration-options-for-dependency-updates

version: 2
updates:
- package-ecosystem: "cargo" # See documentation for possible values
directory: "/" # Location of package manifests
schedule:
interval: "daily"
34 changes: 34 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Description

Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

Fixes # (issue)

## Type of change

Please delete options that are not relevant.

- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] This change requires a documentation update

# How has this been tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

- [ ] Test A
- [ ] Test B

**Test Configuration**:
* Hardware:
* Toolchain:

# Checklist:

- [ ] My code follows [the style guidelines of this project](https://github.com/rust-dev-tools/fmt-rfcs/blob/master/guide/guide.md)
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [ ] My changes generate no new warnings
- [ ] Any dependent changes have been merged
17 changes: 17 additions & 0 deletions .github/stale.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Number of days of inactivity before an issue becomes stale
daysUntilStale: 60
# Number of days of inactivity before a stale issue is closed
daysUntilClose: 7
# Issues with these labels will never be considered stale
exemptLabels:
- pinned
- security
# Label to use when marking an issue as stale
staleLabel: wontfix
# Comment to post when marking an issue as stale. Set to `false` to disable
markComment: >
This issue has been automatically marked as stale because it has not had
recent activity. It will be closed if no further activity occurs. Thank you
for your contributions.
# Comment to post when closing a stale issue. Set to `false` to disable
closeComment: false
17 changes: 17 additions & 0 deletions .github/workflows/annotate_code.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
on: push
name: Annotate code
jobs:
clippy_check:
name: Annotate code
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions-rs/toolchain@v1
with:
toolchain: nightly
components: clippy
override: true
- uses: actions-rs/clippy-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
args: --all-features
37 changes: 37 additions & 0 deletions .github/workflows/armv7.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
on: [push]

name: 'Build: GNU + Linux (ARMv7)'

jobs:
linux_arm7:
name: GNU + Linux (ARMv7)
runs-on: ubuntu-latest
steps:
- name: Checkout codebase
uses: actions/checkout@v2
- name: Setup Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: nightly
target: armv7-unknown-linux-gnueabihf
default: true
profile: minimal
#components: rust-src
- name: Build Oku
uses: actions-rs/cargo@v1
with:
use-cross: true
command: build
args: --release --all-features --target armv7-unknown-linux-gnueabihf
- name: Prepare Oku for upload
run: |
cd ./target/armv7-unknown-linux-gnueabihf/release/
chmod +x ./oku
tar -cvf armv7-oku.gnu+linux.tar \
oku
- name: Upload Oku build artifacts to GitHub
uses: actions/upload-artifact@v2
with:
name: armv7-oku.gnu+linux
path: ./target/armv7-unknown-linux-gnueabihf/release/armv7-oku.gnu+linux.tar
if-no-files-found: error
15 changes: 15 additions & 0 deletions .github/workflows/audit_on_change.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Dependency security audit (on change)
on:
push:
paths:
- '**/Cargo.toml'
- '**/Cargo.lock'
jobs:
security_audit:
name: Security audit
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/audit-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
27 changes: 27 additions & 0 deletions .github/workflows/check_code.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
on: [push]

name: Evaluate codebase

jobs:
code_check:
name: Evaluate codebase
runs-on: ubuntu-latest
steps:
- name: Checkout codebase
uses: actions/checkout@v2
- name: Setup Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: nightly
components: clippy, rustfmt
profile: minimal
- name: Check codebase is properly formatted
uses: actions-rs/cargo@v1
with:
command: fmt
args: -- --check
- name: Check codebase using linter
uses: actions-rs/cargo@v1
with:
command: clippy
args: --all-targets --all-features -- -D warnings
35 changes: 35 additions & 0 deletions .github/workflows/deb.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
on: [push]

name: 'Package: Debian GNU + Linux (x86_64)'

jobs:
deb_x86-64:
name: Debian GNU + Linux (x86_64)
runs-on: ubuntu-latest
steps:
- name: Checkout codebase
uses: actions/checkout@v2
- name: Setup Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: nightly
target: x86_64-unknown-linux-gnu
default: true
profile: minimal
#components: rust-src
- name: Install 'cargo-deb'
uses: actions-rs/cargo@v1
with:
command: install
args: cargo-deb
- name: Build & package Oku
uses: actions-rs/cargo@v1
with:
command: deb
args: --separate-debug-symbols -- --all-features --target x86_64-unknown-linux-gnu
- name: Upload Oku build artifact to GitHub
uses: actions/upload-artifact@v2
with:
name: x86_64-oku.deb.gnu+linux
path: ./target/debian/oku_*_amd64.deb
if-no-files-found: error
33 changes: 33 additions & 0 deletions .github/workflows/format_code.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
on:
push:
branches:
# Push events on master branch
- master

name: Format codebase

jobs:
code_format:
name: Format codebase
runs-on: ubuntu-latest
steps:
- name: Checkout codebase
uses: actions/checkout@v2
with:
token: ${{ secrets.PAT }}
- name: Setup Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: nightly
profile: minimal
components: clippy, rustfmt
- name: Format code files
uses: actions-rs/cargo@v1
with:
command: fmt
- name: Commit changes to code, if any
run: |
git config --global user.name 'Oku'
git config --global user.email '[email protected]'
git diff --quiet && git diff --staged --quiet || git commit -am "Automatically enforce Rust styleguide"
git push
35 changes: 35 additions & 0 deletions .github/workflows/lint_code.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
on:
push:
branches:
# Push events on master branch
- master

name: Lint codebase

jobs:
code_lint:
name: Lint codebase
runs-on: ubuntu-latest
steps:
- name: Checkout codebase
uses: actions/checkout@v2
with:
token: ${{ secrets.PAT }}
- name: Setup Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: nightly
default: true
profile: minimal
components: clippy, rustfmt
- name: Correct code files
uses: actions-rs/cargo@v1
with:
command: clippy
args: --fix -Z unstable-options
- name: Commit changes to code, if any
run: |
git config --global user.name 'Oku'
git config --global user.email '[email protected]'
git diff --quiet && git diff --staged --quiet || git commit -am "Automatically approved suggested code corrections by linter"
git push
38 changes: 38 additions & 0 deletions .github/workflows/mac.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
on: [push]

name: 'Build: macOS (x86_64)'

jobs:
mac_x86-64:
name: macOS (x86_64)
runs-on: macos-latest
steps:
- name: Checkout codebase
uses: actions/checkout@v2
- name: Setup Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: nightly
target: x86_64-apple-darwin
default: true
profile: minimal
#components: rust-src
- name: Build Oku
uses: actions-rs/cargo@v1
with:
use-cross: true
command: build
args: --release --all-features --target x86_64-apple-darwin
- name: Prepare Oku for upload
run: |
cd ./target/x86_64-apple-darwin/release/
strip ./oku
chmod +x ./oku
tar -cvf x86_64-oku.osx.tar \
oku
- name: Upload Oku build artifacts to GitHub
uses: actions/upload-artifact@v2
with:
name: x86_64-oku.osx
path: ./target/x86_64-apple-darwin/release/x86_64-oku.osx.tar
if-no-files-found: error
Loading

0 comments on commit 7146c16

Please sign in to comment.