Skip to content

Commit

Permalink
Merge branch 'test' of https://github.com/Debanjannnn/website into test
Browse files Browse the repository at this point in the history
  • Loading branch information
Debanjannnn committed Aug 31, 2024
2 parents c6ad10f + 5c702df commit 6dc3c37
Show file tree
Hide file tree
Showing 45 changed files with 750 additions and 98 deletions.
8 changes: 1 addition & 7 deletions .github/workflows/cf-pages.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
name: Cloudflare Pages Deployment

on:
push:
branches:
- main
on: [push, pull_request]

jobs:
cf:
Expand All @@ -26,9 +23,6 @@ jobs:
- name: Install Dependencies
run: npm ci

- name: Lint
run: npm run lint

- name: Build
run: npm run build

Expand Down
5 changes: 1 addition & 4 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
name: Linter

on:
push:
branches-ignore:
- main
on: [pull_request]

jobs:
lint:
Expand Down
16 changes: 16 additions & 0 deletions src/App.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
:root {
--side-gap: 0.5rem;
text-rendering: optimizeLegibility;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}

* {
margin: 0;
padding: 0;
}

code {
font-family: source-code-pro, Menlo, Monaco, Consolas, "Courier New",
monospace;
}
3 changes: 2 additions & 1 deletion src/App.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,13 @@ import { Routes, Route } from "react-router-dom";
import "./App.css";

import Home from "./pages/Home";
import Cli from "./pages/Cli";

function App() {
return (
<Routes>
<Route path="/" element={<Home />}></Route>
{/* <Route path="/cli" element={<Cli />}></Route> */}
<Route path="/cli" element={<Cli />}></Route>
</Routes>
);
}
Expand Down
Binary file added src/assets/logo1.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
119 changes: 119 additions & 0 deletions src/components/Commands/Cat.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,119 @@
import classes from "./Commands.module.css";

const Cat = (props) => {
let { fileName } = props;

Check failure on line 4 in src/components/Commands/Cat.jsx

View workflow job for this annotation

GitHub Actions / Lint

'fileName' is missing in props validation
fileName = fileName.trim();

Check failure on line 5 in src/components/Commands/Cat.jsx

View workflow job for this annotation

GitHub Actions / Lint

'fileName.trim' is missing in props validation
fileName.toLowerCase();

Check failure on line 6 in src/components/Commands/Cat.jsx

View workflow job for this annotation

GitHub Actions / Lint

'fileName.toLowerCase' is missing in props validation

switch (fileName) {
case "about":
return (
<div>
<h4 className={classes.description}>
Welcome to ZeroDay Alliance, SNU students passionate about
cybersecurity and ethical hacking. Here’s what you can expect:
</h4>
<ul className={classes.catList}>
<li>
<b>Learn:</b> Stay updated on zero-day vulnerabilities and the
latest security trends.
</li>
<li>
<b>Collaborate:</b> Work with peers on projects and challenges.
</li>
<li>
<b>Share:</b> Exchange resources, tips, and tools for ethical
hacking.
</li>
<li>
<b>Discuss:</b> Engage in conversations about cybersecurity news,
strategies, and innovations.
</li>
<li>
<b>Network:</b> Connect with future professionals in the field.
</li>
</ul>
</div>
);
case "events":
return (
<ul className={classes.catList}>
<li>Event 1</li>
<li>Event 2</li>
</ul>
);
case "teams":
return (
<ul className={classes.catList}>
<li>Team 1</li>
<li>Team 2</li>
<li>Team 3</li>
<li>Team 4</li>
</ul>
);
case "faq":
return <div>FAQ</div>;
case "contact":
return (
<ul className={classes.catList}>
<li>
<span>Website: </span>
<span>
<a
href="https://zeroday-alliance.pages.dev"
target="_blank"
rel="noopener noreferrer"
>
zeroday-alliance.pages.dev
</a>
</span>
</li>
<li>
<span>GitHub: </span>
<span>
<a
href="https://github.com/ZeroDay-Alliance-SNU"
target="_blank"
rel="noopener noreferrer"
>
@ZeroDay-Alliance-SNU
</a>
</span>
</li>
<li>
<span>LinkedIn: </span>
<span>
<a
href="https://www.linkedin.com/company/zeroday-alliance-snu"
target="_blank"
rel="noopener noreferrer"
>
@zeroday-alliance-snu
</a>
</span>
</li>
<li>
<span>Instagram: </span>
<span>
<a
href="https://www.instagram.com/zerodayalliance/"
target="_blank"
rel="noopener noreferrer"
>
@zerodayalliance
</a>
</span>
</li>
</ul>
);
case "":
setTimeout(() => {
window.open("https://takeb1nzyto.space", "_blank");
}, 420);
return <div>🐈</div>;
default:
return <div>{fileName}: No such file or directory</div>;
}
};

export default Cat;
7 changes: 7 additions & 0 deletions src/components/Commands/Commands.module.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
.description {
padding-bottom: 5px;
}

.catList li {
list-style-position: inside;
}
7 changes: 7 additions & 0 deletions src/components/Commands/Echo.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
const Echo = (props) => {
const { message } = props;

Check failure on line 2 in src/components/Commands/Echo.jsx

View workflow job for this annotation

GitHub Actions / Lint

'message' is missing in props validation

return <div>{message}</div>;
};

export default Echo;
22 changes: 22 additions & 0 deletions src/components/Commands/Help.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
const Help = () => {
return (
<>
<span className="command">cat &lt;section&gt;</span> -{" "}
<span>print a section</span>
<br />
<span className="command">clear</span> - <span>clear the screen</span>
<br />
<span className="command">echo &lt;arg&gt;</span> -{" "}
<span>print arguments</span>
<br />
<span className="command">help</span> - <span>print this help</span>
<br />
<span className="command">ls</span> - <span>list all sections</span>
<br />
<span className="command">whoami</span> - <span>about us</span>
<br />
</>
);
};

export default Help;
13 changes: 13 additions & 0 deletions src/components/Commands/Ls.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import { files } from "../../config/fs";

const Ls = () => {
return (
<>
{files.map((file, index) => (
<div key={index}>{file}</div>
))}
</>
);
};

export default Ls;
9 changes: 9 additions & 0 deletions src/components/Commands/Sudo.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
const Sudo = () => {
setTimeout(() => {
window.open("https://www.youtube.com/watch?v=dQw4w9WgXcQ", "_blank");
}, 420);

return <div>sudo: unable to change to root: Operation not permitted</div>;
};

export default Sudo;
12 changes: 12 additions & 0 deletions src/components/Commands/Whoami.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
const Whoami = () => {
return (
<div>
<p>ZeroDay Alliance SNU</p>
<p>
Use <span className="command">cat about</span> for more info.
</p>
</div>
);
};

export default Whoami;
8 changes: 8 additions & 0 deletions src/components/Commands/index.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import Cat from "./Cat";
import Echo from "./Echo";
import Help from "./Help";
import Ls from "./Ls";
import Sudo from "./Sudo";
import Whoami from "./Whoami";

export { Cat, Echo, Help, Ls, Sudo, Whoami };
Loading

0 comments on commit 6dc3c37

Please sign in to comment.