Skip to content

Commit

Permalink
Merge pull request #169 from light-ripple/master
Browse files Browse the repository at this point in the history
Format all files
  • Loading branch information
loannaflip authored Jan 23, 2021
2 parents 5ec73a4 + 7b5d905 commit a736f04
Show file tree
Hide file tree
Showing 13 changed files with 649 additions and 634 deletions.
39 changes: 20 additions & 19 deletions .github/workflows/shell.yml
Original file line number Diff line number Diff line change
@@ -1,25 +1,25 @@
name: Shell

# Relevant to events - https://help.github.com/en/actions/automating-your-workflow-with-github-actions/events-that-trigger-workflows
on:
'on':
pull_request:
types: [ready_for_review]
types:
- ready_for_review
paths:
- "**.sh"
- "Main/ripple.sh"
- "Main/tmux.sh"

- '**.sh'
- Main/ripple.sh
- Main/tmux.sh
jobs:
# Linting
lint:
runs-on: ubuntu-latest
container: debian:stable
container: 'debian:stable'
steps:
- name: Installing dependencies..
run: |
run: >
# Sync repos
# Check for git
if ! apt list --installed 2>/dev/null | grep -qP "^git\/stable.*"; then
if ! apt list --installed 2>/dev/null | grep -qP "^git\/stable.*";
then
# Check if we can install git
if ! apt list | grep -qP "^git\/stable.*"; then
apt update
Expand All @@ -30,13 +30,17 @@ jobs:
fi
# Install git
apt install -y git
elif apt list --installed 2>/dev/null | grep -qP "^git\/stable.*"; then
elif apt list --installed 2>/dev/null | grep -qP "^git\/stable.*";
then
true
else
exit 255
fi
# Check for shellcheck
if ! apt list --installed 2>/dev/null | grep -qP "^shellcheck\s{1}-.*"; then
if ! apt list --installed 2>/dev/null | grep -qP
"^shellcheck\s{1}-.*"; then
# Check if we can install shellcheck
if ! apt list | grep -qP "^shellcheck\s{1}-.*"; then
apt update
Expand All @@ -47,21 +51,18 @@ jobs:
fi
# Install shellcheck
apt install -y shellcheck
elif apt list --installed 2>/dev/null | grep -qP "^shellcheck\s{1}-.*"; then
elif apt list --installed 2>/dev/null | grep -qP
"^shellcheck\s{1}-.*"; then
true
else
exit 255
fi
- name: Checking for execution error(s)..
# Make sure that bash is used
shell: bash
run: |
cd "$GITHUB_WORKSPACE"/Main
./ripple.sh -h | exit 1
- name: Checking for shellcheck error(s)..
# Make sure that bash is used
shell: bash
run: |
cd "$GITHUB_WORKSPACE"/Main
Expand Down
2 changes: 1 addition & 1 deletion .gitpod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ tasks:
- before: brew install shellcheck
vscode:
extensions:
- timonwong.shellcheck@0.9.0:HV7fROO4OHK245UUeWPLRw==
- 'timonwong.shellcheck@0.9.0:HV7fROO4OHK245UUeWPLRw=='
40 changes: 22 additions & 18 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,26 +2,29 @@ name: Bash
language: shell
os: linux
dist: xenial

# Relevant to events - https://help.github.com/en/actions/automating-your-workflow-with-github-actions/events-that-trigger-workflows
on:
'on':
pull_request:
types: [synchronize, opened, reopened, ready_for_review]
types:
- synchronize
- opened
- reopened
- ready_for_review
paths:
- "Main/ripple.sh"
- "Main/tmux.sh"

- Main/ripple.sh
- Main/tmux.sh
jobs:
# Linting
lint:
runs-on: ubuntu-latest
container: debian:stable
container: 'debian:stable'
steps:
- name: Installing dependencies..
run: |
run: >
# Sync repos
# Check for git
if ! apt list --installed 2>/dev/null | grep -qP "^git\/stable.*"; then
if ! apt list --installed 2>/dev/null | grep -qP "^git\/stable.*";
then
# Check if we can install git
if ! apt list | grep -qP "^git\/stable.*"; then
apt update
Expand All @@ -32,13 +35,17 @@ jobs:
fi
# Install git
apt install -y git
elif apt list --installed 2>/dev/null | grep -qP "^git\/stable.*"; then
elif apt list --installed 2>/dev/null | grep -qP "^git\/stable.*";
then
true
else
exit 255
fi
# Check for shellcheck
if ! apt list --installed 2>/dev/null | grep -qP "^shellcheck\s{1}-.*"; then
if ! apt list --installed 2>/dev/null | grep -qP
"^shellcheck\s{1}-.*"; then
# Check if we can install shellcheck
if ! apt list | grep -qP "^shellcheck\s{1}-.*"; then
apt update
Expand All @@ -49,21 +56,18 @@ jobs:
fi
# Install shellcheck
apt install -y shellcheck
elif apt list --installed 2>/dev/null | grep -qP "^shellcheck\s{1}-.*"; then
elif apt list --installed 2>/dev/null | grep -qP
"^shellcheck\s{1}-.*"; then
true
else
exit 255
fi
- name: Checking for execution error(s)..
# Make sure that bash is used
shell: bash
run: |
cd "$GITHUB_WORKSPACE"/Main
./ripple.sh -h | exit 1
- name: Checking for shellcheck error(s)..
# Make sure that bash is used
shell: bash
run: |
cd "$GITHUB_WORKSPACE"/Main
Expand Down
12 changes: 6 additions & 6 deletions Database files/ripple.sql
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
-- Host: Ripple
-- Server OS: Linux
-- --------------------------------------------------------

-- Dumping structure for table 2fa
CREATE TABLE IF NOT EXISTS `2fa` (
`userid` int(11) NOT NULL,
Expand Down Expand Up @@ -964,10 +963,10 @@ INSERT IGNORE INTO `rx_stats` (
)
VALUES
(
999, 'Ripple', '', 'black', '', 0, 1, 1, 1,
1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'JP',
1, 1
999, 'Ripple', '', 'black', '', 0, 1,
1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 'JP', 1, 1
);
-- Dumping structure for table scores
CREATE TABLE IF NOT EXISTS `scores` (
Expand Down Expand Up @@ -1084,7 +1083,8 @@ INSERT IGNORE INTO `users` (
)
VALUES
(
999, NULL, 'Ripple', 'ripple', '0', '*0', '5e/AceVLS7jJtxTJA1U6rmVqrWREYg==',
999, NULL, 'Ripple', 'ripple', '0',
'*0', '5e/AceVLS7jJtxTJA1U6rmVqrWREYg==',
'fo@kab.ot', 1566228790, 4, 1, 1569775752,
0, '', 1, 3145727, 2147483647, 0, 0,
1, 1, '', 'check'
Expand Down
1 change: 1 addition & 0 deletions Main/gencert.sh
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
#!/bin/sh

openssl req -new -x509 -days 3650 -config openssl.cnf -out cert.pem
Loading

0 comments on commit a736f04

Please sign in to comment.