Skip to content

Instantly share code, notes, and snippets.

noeticpenguin /
Created February 5, 2015 01:56
CommunityDebugger visualforce page
<apex:page controller="CommunityDebuggerCtrl" action="{!fetchFailingPage}" showHeader="false" sidebar="false" >
<apex:outputText id="failingPageResponse" escape="false" value="{!failingPageResponse}" />
noeticpenguin / CommunityDebuggerCtrl.cls
Last active April 21, 2021 20:43
Community Debugger controller
View CommunityDebuggerCtrl.cls
public with sharing class CommunityDebuggerCtrl {
public String failingPageResponse { get; set; }
String toLoad {get; private set;}
Map<String, String> params {get; private set;}
String queryString = '?';
public CommunityDebuggerCtrl() {
params = ApexPages.currentPage().getParameters();
toLoad = (String) params.get('page');
noeticpenguin / log.cls
Last active August 29, 2015 14:09
Logging class, for better identification of debug output in massive salesforce log files.
View log.cls
public class log {
// Usage:
//'PageContructorDebug', o, 'why is my object null?');
// log.log('PageContructorDebug', o, 'why is my object null?');
// log.warn('PageContructorDebug', o, 'why is my object null?');
// log.error('PageContructorDebug', o, 'why is my object null?');
// For instance:'PageContructorDebug', o, 'why is my object null?');
// would result in a debug block that looks like this:
View gist:749f13d11f195b0c0460

Using Obj-C with MacRuby/Rubymotion

This little post aims to help you to translate Objective-C Blocks into Ruby blocks. Let's start by taking a look at few examples of iOS API call where blocks are used for animations and enumeration

Ruby Lambda Syntaxes:

Im Rubymotion and MacRuby you can use all the Ruby Lambda syntaxes that are:

block = lambda { |param|  ... }
noeticpenguin / ExampleVFFlowPage.html
Last active August 29, 2015 14:00
Universal Redirect controller for VF Based Pages.
View ExampleVFFlowPage.html
<apex:page Controller="FlowRedirectController">
<flow:interview name="RedirectFlow" interview="{!redirectTo}" finishLocation="{!finishLocation}" >
<!-- This Parameter is *required!* -->
<apex:param name="StartFlow" value="YOUR_FLOW_NAME_HERE" />
Any Params you need to pass into your flow.
<apex:param name="CaseId" value="{!CaseId}"/>

Keybase proof

I hereby claim:

  • I am noeticpenguin on github.
  • I am codefriar ( on keybase.
  • I have a public key whose fingerprint is 2C3A 62E2 921E B13F 87D7 4F0C F975 BA26 3EBA CFAA

To claim this, I am signing this object:

View How to call the code coverage query via execute anonymous
toolingSoapSForceCom.SessionHeader_element sessionEl = new toolingSoapSForceCom.SessionHeader_element();
sessionEl.sessionId = UserInfo.getSessionId();
toolingSoapSForceCom.SforceService service = new toolingSoapSForceCom.SforceService();
service.SessionHeader = sessionEl;
//service.endpoint_x = //Adjust this to your endpoint, if needed...
toolingSoapSForceCom.ApexCodeCoverageAggregateQueryResult queryResult = service.queryApexCodeCoverageAggregate('Select NumLinesCovered From ApexCodeCoverageAggregate');
noeticpenguin /
Created March 21, 2014 13:57
df.code entries
query='SELECT ID, Name, MailingAddress FROM Account'
noeticpenguin / Gruntfile.js
Last active August 29, 2015 13:56
View Gruntfile.js
module.exports = function(grunt) {
jasmine: {
proposalPlus: {
// Include paths for both the local user, if we're in dev mode, as well as share mode
src: ['pp_js' + process.env.USER + '.resource/pp_js/**/*.js',
'pp_ngApp_' + process.env.USER + '.resource/pp_ngApp/**/*.js',