-
- );
- }
- }
-
- return commands;
-}
-
-module.exports = commands;
\ No newline at end of file
diff --git a/react/resume/src/emulation/commands/skills.js b/react/resume/src/emulation/commands/skills.js
deleted file mode 100644
index 2a8aa6d..0000000
--- a/react/resume/src/emulation/commands/skills.js
+++ /dev/null
@@ -1,128 +0,0 @@
-import Colored from '../../helpers/color';
-
-const Title = (p) => {return
{...p.children}
}
-
-const projects = {
- web: [
- {
- name: 'blek! Site',
- source: 'https://github.com/b1ek/blekSite',
- desc: 'Second rewrite of my website in Laravel'
- },
- {
- name: 'homepage.js',
- source: 'https://git.blek.codes/blek/homepage.js',
- desc: 'Third re write of my website in Node/Express.JS/Pug and couple other libs'
- },
- {
- name: 'blek! Sail',
- source: 'https://github.com/b1ek/sail',
- desc: 'A production-ready server for serving Laravel projects'
- },
- {
- name: 'blek! ID',
- source: 'https://github.com/b1ek/blekID',
- desc: 'An auth server. Not really proud of this one, as the code is very spaghetti and practically useless.'
- },
- {
- name: 'blek! Bin',
- source: 'https://git.blek.codes/blek/bin',
- desc: 'Privacy-respecting, js-free alternative to Pastebin. Inspired by Librebin.'
- },
- {
- name: 'College project',
- source: '#',
- desc: 'Work in progress. Planned to be a site with rental apartments for students'
- }
- ]
-}
-
-const skills = {
- web: (
-
- My web experience
-
- Most of my web projects are listed on GitHub.
- I like Express.JS and Laravel, but also want to try Rust.
-
- On frontend, i like to write no-js HTML using
- template engines, or use React for complex apps like this one.
-
- It isn't much.
- I have only one project that is made with
- Qt/C++: CuteSchedule (Cute
- stands fot Qt).
-
- But I do have a lot of experience with C and C++, as I like to write
- a lot of programs in those languages in my free time.
- An example of these programs: f2bin
- , BrainHeck.
-
- Web dev (PHP & JS)
-
- [#####] 100%
- My main work field
- More: skills web
-
-
- C/C++/Rust native dev
- [## ] 40%
- I do this... sometimes
- More: skills nt
-
-
- Linux skills
- [#####] 100%
- Do this all the time. I run linux on my laptop, pc and server
-
-
- Being cis
- [ ] 0%
- Never liked it
-
-
)
-}
\ No newline at end of file
diff --git a/react/resume/src/emulation/commands/social.js b/react/resume/src/emulation/commands/social.js
deleted file mode 100644
index e4b38cf..0000000
--- a/react/resume/src/emulation/commands/social.js
+++ /dev/null
@@ -1,17 +0,0 @@
-import Color from '../../helpers/color';
-const Link = (prop) => {
- return {...prop.children}
-}
-
-module.exports = () => {
- return
- My socials are listed below:
-
- {'>'} My website
- {'>'} Github page
- {'>'} Gitea page
- {'>'} Email
- {'>'} Telegram
- (all links are clickable)
-
;
-}
\ No newline at end of file
diff --git a/react/resume/src/emulation/files.js b/react/resume/src/emulation/files.js
deleted file mode 100644
index 61ce674..0000000
--- a/react/resume/src/emulation/files.js
+++ /dev/null
@@ -1,43 +0,0 @@
-const Hi = (props) => {
- return {...props.children}
-}
-const HR = () => {
- return ;
-}
-
-module.exports = {
- 'README.md': <>
-
# Hello there!
-
- My name is Alice and I am a fullstack web developer.
- I am a trans girl and I live in Russia.
-
- This app was built with React.JS and Parcel.
-
-
## About me
-
- I am vegan and like to listen to hyperpop/jpop.
- Though being vegan, I do eat fried chicken occasionally.
-
- I honestly believe that governments are spying on us
- every time they get a chance to, which is always.
- This is why I run linux and use little to none of proprietary
- software, all my connections are proxied through an offshore server
- and I don't use The Internet when I don't have to.
-
- I like PHP+JS and C. I use PHP+JS for work and C for passion projects,
- as I find it too much of work and possible memory leaks and a lot of nasty
- stuff. To be honestly, I don't imagine building a site or an IDE using just C.
- Perhaps, if speed is very much important, I would look into C++, Rust or Go.
-
- Also I have some experience with stuff like Arduino and/or Raspberry Pi.
- I used to have a team of other makers and we tried to build a vending machine on a bunch of Arduinos and one Raspberry Orange Pi.
-
- Read this app's source code
- on Gitea
- or Github
- >,
-
- 'super_secret_password.txt':
-
UwU
,
-}
\ No newline at end of file
diff --git a/react/resume/src/emulator/index.js b/react/resume/src/emulator/index.js
new file mode 100644
index 0000000..e8c5a0f
--- /dev/null
+++ b/react/resume/src/emulator/index.js
@@ -0,0 +1,8 @@
+module.exports = (terminal) => {
+
+ terminal.writeln('Welcome to my online resume!')
+ terminal.writeln('Type \033[1;32mhelp\033[0m for list of commands')
+ terminal.writeln('');
+
+ require('./zsh')(terminal);
+}
\ No newline at end of file
diff --git a/react/resume/src/emulator/zsh.js b/react/resume/src/emulator/zsh.js
new file mode 100644
index 0000000..c3fe7ba
--- /dev/null
+++ b/react/resume/src/emulator/zsh.js
@@ -0,0 +1,74 @@
+
+import { Terminal } from 'xterm';
+
+/**
+ * @type {Terminal}
+ */
+let terminal;
+
+const prompt = '\033[1;32muser@blek.codes \033[36m~ $ \033[0m';
+let cmd = '';
+
+function pr_char(char) {
+ cmd += char;
+ terminal.write(char);
+}
+
+function exec_cmd() {
+ let c = cmd;
+ reset_cmd();
+ terminal.writeln('zsh: command not found: ' + c);
+ print_prompt();
+}
+
+function print_prompt() {
+ terminal.write(prompt);
+}
+
+function reset_cmd() {
+ cmd = '';
+ terminal.writeln('');
+}
+
+function control_char(char) {
+ const id = char.codePointAt(0);
+ switch (id) {
+
+ // backspace
+ case 127:
+ if (terminal.buffer.active.cursorX == prompt.length) break;
+ terminal.write('\b \b');
+ cmd = cmd.substring(0, cmd.length - 1);
+ break;
+
+ // enter
+ case 13:
+ exec_cmd();
+ break;
+
+ // Ctrl+c
+ case 3:
+ terminal.write('^C');
+ reset_cmd();
+ print_prompt();
+ break;
+
+ default:
+ console.log('Unknown special char: ' + id);
+ break;
+ }
+}
+
+function key(e) {
+ if (RegExp(/^\p{L}/,'u').test(e.key)) {
+ pr_char(e.key);
+ } else {
+ control_char(e.key);
+ }
+}
+
+module.exports = (t) => {
+ terminal = t;
+ terminal.onKey(key);
+ terminal.write(prompt);
+}
\ No newline at end of file
diff --git a/react/resume/src/font/SourceCodeBold.ttf b/react/resume/src/font/SourceCodeBold.ttf
deleted file mode 100644
index e034f70..0000000
Binary files a/react/resume/src/font/SourceCodeBold.ttf and /dev/null differ
diff --git a/react/resume/src/font/SourceCodeMedium.ttf b/react/resume/src/font/SourceCodeMedium.ttf
deleted file mode 100644
index 1e42b5e..0000000
Binary files a/react/resume/src/font/SourceCodeMedium.ttf and /dev/null differ
diff --git a/react/resume/src/font/SourceCodeRegular.ttf b/react/resume/src/font/SourceCodeRegular.ttf
deleted file mode 100644
index daad874..0000000
Binary files a/react/resume/src/font/SourceCodeRegular.ttf and /dev/null differ
diff --git a/react/resume/src/font/SourceCodeSemiBold.ttf b/react/resume/src/font/SourceCodeSemiBold.ttf
deleted file mode 100644
index 7dc26d9..0000000
Binary files a/react/resume/src/font/SourceCodeSemiBold.ttf and /dev/null differ
diff --git a/react/resume/src/font/sourcecode.css b/react/resume/src/font/sourcecode.css
deleted file mode 100644
index 95ea7b6..0000000
--- a/react/resume/src/font/sourcecode.css
+++ /dev/null
@@ -1,23 +0,0 @@
-@font-face {
- font-family: 'Source Code Pro';
- src: url(./SourceCodeRegular.ttf);
- font-weight: 400;
-}
-
-@font-face {
- font-family: 'Source Code Pro';
- src: url(./SourceCodeMedium.ttf);
- font-weight: 500;
-}
-
-@font-face {
- font-family: 'Source Code Pro';
- src: url(./SourceCodeSemiBold.ttf);
- font-weight: 600;
-}
-
-@font-face {
- font-family: 'Source Code Pro';
- src: url(./SourceCodeBold.ttf);
- font-weight: 700;
-}
\ No newline at end of file
diff --git a/react/resume/src/helpers/color.js b/react/resume/src/helpers/color.js
deleted file mode 100644
index a6c787d..0000000
--- a/react/resume/src/helpers/color.js
+++ /dev/null
@@ -1,3 +0,0 @@
-module.exports = (p) => {
- return {...p.children}
-}
\ No newline at end of file
diff --git a/react/resume/src/index.html b/react/resume/src/index.html
index 5aba79d..3f231d9 100644
--- a/react/resume/src/index.html
+++ b/react/resume/src/index.html
@@ -1,12 +1,13 @@
-
-
- Resume debug mode
-
-
-
-
-
-
-
+
+ resume.js
+
+
+
+
+
+
+
+
+