Skip to content

Instantly share code, notes, and snippets.

View MbuguaCaleb's full-sized avatar
🏠
Bsc Electronic and Computer Engineering (Above all Born Again. Romans 13:11 )

Mbugua Caleb MbuguaCaleb

🏠
Bsc Electronic and Computer Engineering (Above all Born Again. Romans 13:11 )
View GitHub Profile
SSH(Entails to when a client is communicating to a server)
SECURE SHELL
PROROCOL TO COMMUNINCATE WITH OTHER COMPUTERS AND SIMILAR TO (https,http,ftp)
Used to do just about anything in a remote computer and mostly used via the terminal/commandLine
Traffic is Enccrypted
Can also be used via GUI eg in WINSCP
Can also be used in ftp..file zilla
@MbuguaCaleb
MbuguaCaleb / Postgres.txt
Last active August 14, 2019 07:52
POSTGRES REPLICATION
# Viewing your Posgtres Clusters
sudo pg_lsclusters
# create a second postgres cluster
sudo pg_createcluster 10 replica1
#checking the status of the cluster
sudo pg_ctlcluster 10 replica1 status
sudo systemctl status postgresql@10-main
@MbuguaCaleb
MbuguaCaleb / index.html
Created August 19, 2019 14:35
Pluralsight Login Clone
<div id="wrapper">
<div id="left">
<div id="signin">
<div class="logo">
<img src="https://image.ibb.co/hW1YHq/login-logo.png" alt="Sluralpright" />
</div>
<form>
<div>
<label>Email or username</label>
<input type="text" class="text-input" />
@MbuguaCaleb
MbuguaCaleb / SSH GIST
Last active March 18, 2021 10:24
A GIST FOR SSH
Private and Public Keys
Gaining access to a remote server
1)It is SSH-Secure Shell Protocol to communicate with other computers .It is similar to Protocals like https,hhtp and ftp)
2)Do just anything in the remote Computer (Make files,,,etc)
3)Traffic is Encrypted while using ssh..Used Mostly in Terminal/Commandline..Can also be used in GUI EG SCP...ALSO WITH FTP CLIENTS
Like filezilla
@MbuguaCaleb
MbuguaCaleb / main.dart
Created August 12, 2020 09:35
Dart Primer tutorial by Net Ninja on the basics of dart
void main() {
//Instantiating a class
User userOne=User('caleb', 24);
//calling an attribute/property of the class
print(userOne.username);
print(userOne.age);
User userTwo = User('mercy',23);
void main() {
/*Map is a set of key value pairs similar to
* object literals in javascript and dictionaries in
* python
*
*/
Map student ={
'name':"Mbugua Caleb","age":"24"
};
@MbuguaCaleb
MbuguaCaleb / beginning HTML.txt
Last active September 7, 2020 18:16
The Internet
(a)Internet is a global network of computers.
(b)Each Commputer/Router has an IP address (which is unique to it)Remeber the concept of public and private IP address..(in a local
network computers in the same network each have a unique private IP address)
(c)Computers talk to each other using the TCP/IP protocal.
(d)HTTP handles web traffic (request/response)
(e)DNS is used to Map IP addresses to domain names.
-- What is the result?
SELECT MAX(id) FROM your_table;
-- Then run...
-- This should be higher than the last result.
SELECT nextval('your_table_id_seq');
-- If it's not higher... run this set the sequence last to your highest id.
-- (wise to run a quick pg_dump first...)
@MbuguaCaleb
MbuguaCaleb / csharp_fundamentals.cs
Last active February 17, 2021 03:15
Fundamentals of the C# Programming Language.
#Strings and String Methods.
using System;
namespace csharp_one
{
class Program
{
static void Main(string[] args)
{
@MbuguaCaleb
MbuguaCaleb / .java
Last active February 17, 2021 13:28
Java Fundamentals
//Strings
package com.caleb;
public class Main {
public static void main(String[] args) {
String hello =" CALEB" + "MBUGUA!! ";
//Concat strings
//String is a class therefore it has methods we canbe able to access.
System.out.println(hello.toLowerCase());