Skip to content

Instantly share code, notes, and snippets.

View pi3r's full-sized avatar
🐒
💻

Pierre Nespo pi3r

🐒
💻
View GitHub Profile
@pi3r
pi3r / todo.md
Last active November 18, 2015 11:40
TODO
  • pebon
  • pebon
@pi3r
pi3r / gist:d9308260308776123005
Last active September 13, 2015 12:43
deliveroolazyness
setInterval(function(){document.title = $(".graph-point.active").last().find(".title-m").html()}, 2000)
func Stream(ctx context.Context, out <-chan Value) error {
for {
v, err := DoSomething(ctx)
if err != nil {
return err
}
select {
case <-ctx.Done():
return ctx.Err()
case out <- v:
@pi3r
pi3r / gist:6462228
Last active December 22, 2015 10:58
Zendesk Feedback Tab with SnapEngage

1. Create a Feedback Tab with the following Custom Css:

</style>
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.0.3/jquery.min.js"></script>
<script>
  var j = jQuery.noConflict();
  j(document).ready(function(){
    j('.preferChat').prop({ href: "#snapengage" });
    j('.preferChat').on('click', function(e){
      e.preventDefault();
@pi3r
pi3r / gist:5916014
Created July 3, 2013 07:12
Extract attachments from a given ticket
// Api url to fetch audits "/api/v2/tickets/42/audits.json", you'll need to handle the pagination.
extractAttachmentsFromTicketAudits: function(audits){
var attachments = [];
_.each(audits, function(audit){
_.each(audit.events, function(event){
if (event.attachments && event.att
[
{
"url": "http://www.xyz.com",
"label": "XYZ"
},
{
"url": "http://www.plop.com",
"label": "PLOP"
},
{
def initialize(app = nil, line_mapping = nil)
@@line_map = line_mapping
@@lines = Hash.new(Hash.new(0))
super(app)
end

Zendesk Apps:

Here's the default design of a Zendesk App:

(function() { 
  return {
  };
}());
EXPEDITEUR
ENTREPRISE
ADRESSE
A VILLE, le DATE
Monsieur le Président,
J'ai l'honneur de vous faire part de mon intention de démissionner de mon poste de [***] que j'occupe