# set http proxy
export http_proxy=http://PROXYHOST:PROXYPORT
# set http proxy with user and password
export http_proxy=http://USERNAME:PASSWORD@PROXYHOST:PROXYPORT
# set http proxy with user and password (with special characters)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# This script cleans all cache for Microsoft Teams on Linux | |
# Tested on Ubuntu-like, Debian by @necrifede, Arch Linux by @lucas-dclrcq and Manjaro with flatpak by @danie1k. Feel free to test/use in other distributions. | |
# Tested Teams via snap package. | |
# Tested Teams via flatpak package. | |
# | |
# How to use in terminal: | |
# ./clear_cache_MS_Teams.sh ( deb-stable | deb-insider | snap | flatpak ) | |
# or |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Grab the url of a publicly embeddable video hosted on vimeo | |
* @param str $video_url The "embed" url of a video | |
* @return str The url of the thumbnail, or false if there's an error | |
*/ | |
function grab_vimeo_thumbnail($vimeo_url){ | |
if( !$vimeo_url ) return false; | |
$data = json_decode( file_get_contents( 'http://vimeo.com/api/oembed.json?url=' . $vimeo_url ) ); |
TLDR: The cascade={"remove"}
is like a "software" onDelete="CASCADE"
, and will remove objects from the database only when an explicit call to $em->remove()
occurs. Thus, it could result in more than one object being deleted. orphanRemoval
can remove objects from the database even if there was no explicit call to ->remove()
.
I answered this question a few times to different people so I will try to sum things up in this Gist.
Let's take two entities A
and B
as an example. I will use a OneToOne relationship in this example but it works exactly the same with OneToMany relationships.
class A