Skip to content

Instantly share code, notes, and snippets.

View ckruse's full-sized avatar

Christian Kruse ckruse

View GitHub Profile
pub async fn create_mention(
source_url: String,
target_url: String,
object_type: &str,
id: i32,
author: String,
title: String,
conn: &mut PgConnection,
) -> Result<Mention, sqlx::Error> {
let now = chrono::Utc::now().naive_utc();
import hashlib
import random
class FilterModule(object):
def salt(self):
ALPHABET = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"
for i in range(16):

Keybase proof

I hereby claim:

  • I am ckruse on github.
  • I am ckruse ( on keybase.
  • I have a public key whose fingerprint is BC5D 9F4E F7FB 4382 6056 E834 B8E0 F342 A99A 9D73

To claim this, I am signing this object:

context "change" do
scenario "user updates a existing group", js: true do
project.user_projects.create!(user_id: user.user_id)
visit edit_project_calendar_group_path(project.slug, group)
expect(page.body).to have_field Calendar::Group.human_attribute_name :name
expect(page.body).to have_button 'Speichern'
fill_in Calendar::Group.human_attribute_name(:name), with: "Test-Group CK"
// -*- coding: utf-8 -*-
use std::os;
use std::sync::Future;
use std::io::BufferedReader;
use std::io::File;
fn main() {
let args = os::args();
let mut results: Vec<Future<_>> = vec![];
if [ "$2" = "full" ]; then
scrot $TMPFILE