This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@font-face { | |
font-family: "JetBrains Mono"; | |
src: url("https://raw.githubusercontent.com/ryanoasis/nerd-fonts/master/patched-fonts/JetBrainsMono/Ligatures/Regular/complete/JetBrains%20Mono%20Regular%20Nerd%20Font%20Complete.ttf"); | |
font-weight: normal; | |
font-style: normal; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const [hosts, streams] = document.querySelectorAll('.downloaders_list'); | |
/** | |
* Get list of services in alldebrid platform. | |
* | |
* @param {NodeListOf<Element>} services Use either `hosts` or `streams` | |
* @returns Object { downloaders_available?: string[]; downloaders_unavailable?: string[] } | |
*/ | |
function getServiceList(services) { | |
let group = {}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Injectable } from '@angular/core'; | |
import { CanLoad, Router } from '@angular/router'; | |
import { Observable } from 'rxjs'; | |
import { AuthQuery } from './state/auth.query'; | |
import { tap, take } from 'rxjs/operators'; | |
@Injectable({ | |
providedIn: 'root', | |
}) | |
export class AuthGuard implements CanLoad { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Convert object to url params. | |
* | |
* @param obj Object | |
*/ | |
function objToUrlParams(obj) { | |
return Object.entries(obj) | |
.map(([key, val]) => (!val ? null : `${key}=${val}`)) | |
.filter(Boolean) | |
.join('&'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { FormGroup } from '@angular/forms'; | |
export function MustMatch(controlName: string, matchingControlName: string) { | |
return (formGroup: FormGroup) => { | |
const control = formGroup.controls[controlName]; | |
const matchingControl = formGroup.controls[matchingControlName]; | |
if (matchingControl.errors && !matchingControl.errors.mustMatch) { | |
return; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
doskey subl="C:\Program Files\Sublime Text 2\sublime_text.exe" $* | |
doskey ls=ls $1 --color | |
doskey ll=ls -la --color | |
doskey sbl = sublime $* | |
doskey sshs = ssh [email protected] | |
doskey oocd = openocd-x64-0.6.1 -f .\stm32f4discovery.cfg | |
doskey oocd7 = openocd-x64-0.7.0 -f .\stm32f4discovery.cfg | |
doskey sshkey = type C:\Users\dcrystalj\.ssh\id_rsa.pub | clip & echo "ssh key in clipboard" | |
:: Git |