Skip to content

Instantly share code, notes, and snippets.

Alexandru Guzinschi vimishor

  • Romania
Block or report user

Report or block vimishor

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View crash.zig
pub const Box = struct {
field: i32,
pub fn main() void {
var box = Box { .field = 0 };
box.*.field = 1; // crash aici
var boxPtr = &box;
#!/usr/bin/env bash
# Register a new deploy-key on Bitbucket
# Usage: ./ <username> <password> key-test ~/.ssh/ vimishor my-super-repo
vimishor /
Created Apr 29, 2015
Search from CLI
#!/usr/bin/env sh
# Search from CLI with support for sorting results by the number
# of downloads or favorites.
# Temporary solution for
# Dependencies:
# - [curl](
# - [jq](
vimishor / pre-commit
Created Apr 14, 2015
Prevents debug traces and sensitive data to be commited.
View pre-commit
# Prevents debug traces and sensitive data to be commited.
# What to search for
# Prevent the commit if something is found.
# default: true
# Build Zsh from sources on Ubuntu.
# From and sources INSTALL file.
# Some packages may be missing
sudo apt-get install -y git-core gcc make autoconf yodl libncursesw5-dev texinfo
git clone git://
cd zsh
vimishor / 503.html
Last active Dec 31, 2015
Custom 503 page while deploy on openshift | License: MIT
View 503.html
<!DOCTYPE html>
<title>Deploy in progress. Please try again in few minutes</title>
<style type="text/css" />
body {color: #666; text-align: center; font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; sans-serif; margin:0; width: 800px; margin: auto; font-size: 14px; }
h1 { font-size: 56px; line-height: 100px; font-weight: normal; color: #456; }
h2 { font-size: 24px; color: #666; line-height: 1.5em; }
h3 { color: #456; font-size: 20px; font-weight: normal; line-height: 28px; }
hr { margin: 18px 0; border: 0; border-top: 1px solid #EEE; border-bottom: 1px solid white; }
View FooController.php
// src/Foobar/Controller/FooController.php
namespace Foobar\Controller;
class FooController
public function helloAction($request)
vimishor / skype.bash
Created Jul 14, 2013
Skype install on ubuntu
View skype.bash
sudo add-apt-repository "deb $(lsb_release -sc) partner"
sudo apt-get update
sudo apt-get install skype && sudo apt-get -f install
vimishor / gist:5950053
Last active Dec 19, 2015
Take notes inside your browser, with Sublime Text flavor.
View gist:5950053
// paste in address bar
data:text/html,<title>Browser Editor</title><style type="text/css">#e{font-size: 16px; position:absolute;top:0;right:0;bottom:0;left:0;}</style><div id="e"></div><script src="" type="text/javascript" charset="utf-8"></script><script>var e=ace.edit("e");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/javascript");</script>

Există greșeli în următorul cod ?

function valid_email($email) {
    //Regular expression string to evaluate the email
    $regex = '/^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$/';

    //Checks for a match to the expression
    if (preg_match($regex, $email)) {
                //Check for valid domain(helps avoid eronious emails)
You can’t perform that action at this time.