This file contains 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
blueprint: | |
# Custom control via IKEA Symfonisk Gen2 | |
# Based on https://community.home-assistant.io/t/z2m-ikea-symfonisk-gen2-e2123-media-control-v1-55/559523 Shawsky | |
name: Z2M - IKEA Symfonisk sound controller GEN2 custom actions | |
description: | |
'Trigger custom actions with an IKEA Symfonisk sound controller GEN2 via Zigbee2MQTT (Z2M)' | |
domain: automation | |
input: | |
remote: |
This file contains 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 your favorite browser, goto your reddit profile page and open the comments list | |
- Open the browser developer tools (F12) | |
- Paste the code in this gist into the console and hit enter | |
- Observe how comments are deleted one by one | |
- When all comments on the page have been deleted, refresh the page and execute the script again on the remaining comments |
This file contains 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
(function deleteComments() { | |
var deleteButtons = document.querySelectorAll('[data-event-action="delete"]'); | |
[].forEach.call(deleteButtons, function(element) { | |
element.click(); | |
}); | |
var trigger = setInterval(function(){ | |
var yesButton = document.querySelector('.yes'); | |
if (yesButton === null) { | |
clearInterval(trigger); | |
var nextButton = document.querySelector('span.next-button > a'); |
This file contains 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
# Get all the provisioned packages | |
$Packages = (get-item 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Appx\AppxAllUserStore\Applications') | Get-ChildItem | |
# Filter the list if provided a filter | |
$PackageFilter = $args[0] | |
if ([string]::IsNullOrEmpty($PackageFilter)) | |
{ | |
echo "No filter specified, attempting to re-register all provisioned apps." | |
} | |
else |
This file contains 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.Web.Mvc; | |
using MyProject.ModelBinders; | |
using Kendo.Mvc.UI; | |
namespace MyProject.CustomAttributes | |
{ | |
public class CustomDataSourceRequestAttribute : DataSourceRequestAttribute | |
{ | |
public override IModelBinder GetBinder() | |
{ |