Skip to content

Instantly share code, notes, and snippets.

@fish0185
fish0185 / resize ubuntu on virtualbox
Last active April 26, 2018 01:08
resize ubuntu on virtualbox
// how to resize/allocate new partition
https://www.youtube.com/watch?v=cDgUwWkvuIY
// prepare work
https://technology.amis.nl/2017/01/30/ubuntu-vm-virtualbox-increase-size-disk-make-smaller-exports-distribution/
0. backup
1. First detach the image from the VM
// create vdi file - cmd command
2. “c:\Program Files\Oracle\VirtualBox\VBoxManage.exe” clonemedium –format VDI kafkaworkshoposajava-disk1.vmdk kafkaworkshoposajava-disk1.vdi
@fish0185
fish0185 / web-servers.md
Last active July 3, 2018 04:32 — forked from willurd/web-servers.md
[Big list of http static server one-liners] #Server

Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.

Discussion on reddit.

Python 2.x

$ python -m SimpleHTTPServer 8000
@fish0185
fish0185 / setup proxy fiddler
Created March 12, 2018 07:04
setup proxy fiddler
## add ##
<system.net>
<defaultProxy>
<proxy
proxyaddress="http://127.0.0.1:fillderport"
bypassonlocal="false"
/>
</defaultProxy>
</system.net>
@fish0185
fish0185 / use dnSpy debug or edit dotnet dll
Created March 2, 2018 07:22
use dnSpy debug or edit dotnet dll
case 1 for website.
0. install dnSpy binary https://github.com/0xd4d/dnSpy
1. start as admin mode
3. attch the running iis process//to find the process id please use iis manager iis -> worker process, ensure the website/api been hit to
start the process
4. debug -> windows -> module. doule click the dll you need to edit
5. select the method right click edit method, on new window please edit the source code and compile it//need to fixed the compile issue if
not able compile
6. save the module then repalce the origin dll
7. finish
@fish0185
fish0185 / README.md
Created March 1, 2018 03:18 — forked from hofmannsven/README.md
My simply Git Cheatsheet
@fish0185
fish0185 / ProjectName.sln.DotSettings
Created October 4, 2017 10:48 — forked from JavadocMD/ProjectName.sln.DotSettings
A nice DotSettings file for JetBrains Rider projects.
<wpf:ResourceDictionary xml:space="preserve" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:s="clr-namespace:System;assembly=mscorlib" xmlns:ss="urn:shemas-jetbrains-com:settings-storage-xaml" xmlns:wpf="http://schemas.microsoft.com/winfx/2006/xaml/presentation">
<s:Boolean x:Key="/Default/CodeEditing/Intellisense/CodeCompletion/IntelliSenseCompletingCharacters/CSharpCompletingCharacters/UpgradedFromVSSettings/@EntryValue">True</s:Boolean>
<s:Boolean x:Key="/Default/CodeInspection/Highlighting/IdentifierHighlightingEnabled/@EntryValue">True</s:Boolean>
<s:String x:Key="/Default/CodeInspection/Highlighting/InspectionSeverities/=SuggestVarOrType_005FSimpleTypes/@EntryIndexedValue">DO_NOT_SHOW</s:String>
<s:String x:Key="/Default/CodeInspection/Highlighting/InspectionSeverities/=UnassignedField_002ECompiler/@EntryIndexedValue">DO_NOT_SHOW</s:String>
<s:String x:Key="/Default/CodeStyle/CodeCleanup/RecentlyUsedProfile/@EntryValue">Default: Reformat Code</s:String>
<s:String x:Key="/Defaul

How to add an image to a gist

  1. Create a gist if you haven't already.
  2. Clone your gist:
    # make sure to replace `<hash>` with your gist's hash
    git clone https://gist.github.com/<hash>.git # with https
    git clone git@gist.github.com:<hash>.git     # or with ssh
0. Install-Package AWSSDK.SQS which will install dependency package AWSSDK.Core as well
1. Setup AWS user credentials.
1.1 login aws account, right upper corner click your name, and click My Security Credentials
1.2 left of submenu click users and create one
1.3 create a group as well, add permissions to the group. e.g. AmazonSQSFullAccess
1.4 add user to the group
2. goto SQS service. create a queue (you can give user certain permissions on permissiong tab)
http://docs.aws.amazon.com/sdk-for-net/v3/developer-guide/sqs-apis-intro.html
Once your chosen LESS compiler is downloaded, installed, and ready for action, the following are your steps to be performed:
1. Create a new folder named css in the main directory at the same level as the fonts, img, js, and less folders.
2. Use one of the following two methods to add your project's main folder (the parent folder of css, fonts, img, less, and so on) to your compiler: Drag-and-drop the folder into the application window Alternatively, navigate to the application's File | New Project menu to add the parent folder
3. You should see that the application loads the LESS files (and perhaps other files) into its window. Search or scan for the less/ bootstrap.less file.
4. Right-click on bootstrap.less. Select Set output path (or your application's similar option). Navigate to the css folder you created earlier. The file should automatically be named bootstrap.css. Click on Select.
5. With the output path set, now click on Compile.