Skip to content

Instantly share code, notes, and snippets.

View favrik's full-sized avatar
🏀

Favio Manriquez favrik

🏀
View GitHub Profile
.
├── css
│   └── testor.css
├── templates
│   └── html.tpl.php
└── testor.info
@favrik
favrik / gist:5659912
Created May 28, 2013 01:09
Email failing wp_mail() wordpress godaddy
Basically this: http://drupal.org/node/1174866 Could be related to Godaddy and/or more hosts
If you notice that your phpinfo() has sendmail_from set to "me@localhost", suspect!
- Install WP SMTP Mail
- Configure with relay server found in php.ini (via FTP)
- Make sure you have an email address on the domain
- No Auth, No Encryption
- Enjoy!
@favrik
favrik / gist:5492724
Created April 30, 2013 23:34
Replazor of strings
find . -type f -print0 | xargs -0 sed -i 's/->err(/->error(/g'
find . -type f -print0 | xargs -0 sed -i 's/->warn(/->warning(/g'
@favrik
favrik / vim-regex.md
Created March 6, 2013 11:09
Replace string with another string at same indentation level

Input

                  =r.text_field :first_name
                .control-group
                  =r.label :middle_name, "Middle Name", class: "control-label"

Output

@favrik
favrik / gist:4527816
Created January 14, 2013 04:43
Playing with d3. ^_^
<!DOCTYPE html>
<meta charset="utf-8">
<style>
body {
font: 10px sans-serif;
}
2012.11.13-14:47:30.548: WARN - CpuUsageLogger: avgCpuTime=227 threadCount=59
2012.11.13-14:47:30.550: WARN - CpuUsageLogger: THREAD 14 CPU 0.0 BLOCKED
sun.nio.ch.ServerSocketChannelImpl.accept(ServerSocketChannelImpl.java:136)
org.eclipse.jetty.server.nio.SelectChannelConnector.accept(SelectChannelConnector.java:109)
org.eclipse.jetty.server.AbstractConnector$Acceptor.run(AbstractConnector.java:938)
org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:608)
org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:543)
java.lang.Thread.run(Thread.java:662)
---
THREAD 17 CPU 0.0 BLOCKED
2012.11.13-12:10:03.839: ERROR - Cannot start JettyStatisticsLogger. Statistics Handler MBean is not initialized. Please check Jetty configuration!
2012.11.13-12:10:03.844: INFO - JettyStatisticsLogger enabled: autoLogging=true, started=true
2012.11.13-12:10:05.053: WARN - Could not start CMSOldGenerationManager
java.lang.IllegalStateException: Could not find MemoryPoolMXBean with name CMS Old Gen
at com.chess.live.server.monitoring.CMSOldGenerationManager$Manageable.start(CMSOldGenerationManager.java:57)
at com.chess.live.server.DemoChessServlet.init(DemoChessServlet.java:263)
at com.chess.live.AbstractChessServlet.init(AbstractChessServlet.java:87)
at org.eclipse.jetty.servlet.ServletHolder.initServlet(ServletHolder.java:477)
at org.eclipse.jetty.servlet.ServletHolder.doStart(ServletHolder.java:293)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
[root@localhost bin]# gdb /usr/bin/java core.4368
GNU gdb (GDB) CentOS (7.0.1-42.el5.centos.1)
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
#
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x00002abb2551a8b1, pid=4299, tid=1105414464
#
# JRE version: 6.0_37-b06
# Java VM: Java HotSpot(TM) 64-Bit Server VM (20.12-b01 mixed mode linux-amd64 )
# Problematic frame:
# V [libjvm.so+0x87a8b1] YieldingFlexibleWorkGang::start_task(YieldingFlexibleGangTask*)+0x11
#
@favrik
favrik / vagrant.org
Created October 18, 2012 06:42
CentOS Box for Vagrant