$ docker
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
| //Zoom/Pan Component | |
| //by Rick Companje, Nov 1, 2018. | |
| //Enjoy! | |
| var img; | |
| var w, h, tow, toh; | |
| var x, y, tox, toy; | |
| var zoom = .01; //zoom step per mouse tick | |
| function preload() { |
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
| public partial class MainWindow : Window | |
| { | |
| public MainWindow() | |
| { | |
| InitializeComponent(); | |
| } | |
| private void BrowserView_OnFrameLoadEnd(object sender, FrameLoadEndEventArgs e) | |
| { | |
| //Please note that the delegate is marked as ‘async’ |
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
| using System; | |
| using System.Text.RegularExpressions; | |
| using System.Reflection; | |
| namespace RegexLibraryBuilder | |
| { | |
| /// <summary> | |
| /// Summary description for Class1. | |
| /// </summary> | |
| class RegexBuilderMain | |
| { |
Steps to deploy a Node.js app to DigitalOcean using PM2, NGINX as a reverse proxy and an SSL from LetsEncrypt
If you use the referal link below, you get $10 free (1 or 2 months) https://m.do.co/c/5424d440c63a
I will be using the root user, but would suggest creating a new user
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
| /** | |
| * Copyright 2019 Google LLC. | |
| * SPDX-License-Identifier: Apache-2.0 | |
| */ | |
| function getEnvironment() { | |
| var environment = { | |
| spreadsheetID: "<REPLACE WITH YOUR SPREADSHEET ID>", | |
| firebaseUrl: "<REPLACE WITH YOUR REALTIME DB URL>" | |
| }; |
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 bpy | |
| # https://blender.stackexchange.com/questions/5281/blender-sets-compute-device-cuda-but-doesnt-use-it-for-actual-render-on-ec2 | |
| bpy.context.user_preferences.addons['cycles'].preferences.compute_device_type = 'CUDA' | |
| bpy.context.user_preferences.addons['cycles'].preferences.devices[0].use = True | |
| bpy.context.scene.cycles.device = 'GPU' | |
| bpy.data.scenes["Scene"].render.filepath = "/tmp/output.png" | |
| bpy.ops.render.render(write_still=True) |
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
| sudo yum -y install freetype freetype-devel libpng-devel | |
| sudo yum -y install mesa-libGLU-devel | |
| sudo yum -y install libX11-devel mesa-libGL-devel perl-Time-HiRes | |
| # Insert any url for Linux 64 bit blender | |
| # https://builder.blender.org/download/ | |
| wget 'https://builder.blender.org/download/blender-2.78-81d7ff84769-linux-glibc219-x86_64.tar.bz2' | |
| tar -jxvf blender*.tar.bz2 |
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
| void Main() | |
| { | |
| var searchWord = "TextToSearchFor"; | |
| var searchPattern = "*.js"; | |
| var sourceFolder = @"C:\_Dev\TFS\MyProject\Source\"; | |
| var defaultProgram = @"C:\Program Files (x86)\Notepad++\notepad++.exe"; | |
| List<string> allFiles = new List<string>(); | |
| var fileCount = 0; |