Contexto
Breve descrição da alteração realizada e do sistema afetado.
Problema
Descrição objetiva do problema gerado após a mudança.
| async function retry<T>(fn: () => Promise<T>, retries: number = 5) { | |
| try { | |
| return await retry() | |
| } catch (err) { | |
| if (retries > 0) { | |
| console.log("Retrying...") | |
| return await retry(fn, retries - 1) | |
| } | |
| throw err | |
| } |
| export type Class<T = unknown> = new (...args: unknown[]) => T | |
| class DependencyManager { | |
| // eslint-disable-next-line no-use-before-define | |
| private static instance: DependencyManager | |
| public deps: Record<string, Class> = {} | |
| private constructor() {} | |
| public static getInstance(): DependencyManager { |
| export default function random(length) { | |
| let text = ''; | |
| const possible = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789'; | |
| for (let i = 0; i < length; i += 1) { | |
| text += possible.charAt(Math.floor(Math.random() * possible.length)); | |
| } | |
| return text; | |
| } |
| { | |
| // Define o tema do VSCode | |
| "workbench.colorTheme": "Atom One Dark", | |
| // Aumenta a fonte do terminal | |
| "terminal.integrated.fontSize": 14, | |
| // Define o tema dos ícones na sidebar | |
| "workbench.iconTheme": "material-icon-theme", | |
| "workbench.startupEditor": "newUntitledFile", |
| import { Dimensions } from 'react-native'; | |
| const widthPercentageToDP = widthPercent => { | |
| const screenWidth = Dimensions.get('window').width; | |
| const elemWidth = parseFloat(widthPercent); | |
| return PixelRatio.roundToNearestPixel((screenWidth * elemWidth) / 100); | |
| }; | |
| const heightPercentageToDP = heightPercent => { | |
| const screenHeight = Dimensions.get('window').height; |
| using System.Collections; | |
| using System.Collections.Generic; | |
| using UnityEngine; | |
| public class PlayerBehaviourScript : MonoBehaviour { | |
| private float x; | |
| private float y; | |
| private float z; | |
| public bool canJump = true; |
| #include <iostream> | |
| using namespace std; | |
| bool is_palindrom(int number); | |
| int main() { | |
| int number; | |
| le (number > 0) { |
| #!/bin/bash | |
| DIR=~/ | |
| FILE_PROFILE=.profile | |
| FILE_BASH=.zshrc | |
| DOWNLOADS=Downloads | |
| cd ~/Downloads/ | |
| wget -c --tries=3 -O ${$DIR$DOWNLOADS}"/jdk.tar.gz http://download.oracle.com/otn-pub/java/jdk/8u161-b12/2f38c3b165be4555a1fa6e98c45e0808/jdk-8u161-linux-x64.tar.gz?AuthParam=1522841007_f9dd76d4f638494498691469a78af142 | |
| tar -xvf ${$DIR$DOWNLOADS}/jdk.tar.gz |