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
// Check form | |
RACSignal *formValidate = [RACSignal | |
combineLatest:@[self.textField.rac_textSignal] | |
reduce:^(NSString *email) { | |
NSRange at = [email rangeOfString:@"@"]; | |
return @(at.location != NSNotFound); | |
}]; | |
[[formValidate map:^id(NSNumber *isValid) { | |
return isValid; |
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
buildNumber=$(/usr/libexec/PlistBuddy -c "Print CFBundleVersion" "$INFOPLIST_FILE") | |
buildNumber=$(($buildNumber + 1)) | |
/usr/libexec/PlistBuddy -c "Set :CFBundleVersion $buildNumber" "$INFOPLIST_FILE" |
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
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> | |
<html> | |
<!-- | |
Instructions: | |
1. Get UDID of the client device via iTunes. | |
2. Send the device UDID to developer portal. | |
3. Generate a new build with the UDID of the client. | |
4. Archive to enterprise distribribution and save in your machine. | |
5. Change MyApp.plist in this file to your generate plist file, the |
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
<!-- CSS --> | |
<style type="text/css"> | |
/* verifica se esta na vertical ou horizontal */ | |
#aviso-vertical { display: none; background:red; color:white; padding:20px; margin-top:100px; } | |
#aviso-vertical p { text-align:center; font-family: 'Trebuchet MS'; margin-left: -295px; font-size:22px; } | |
@media only screen and (orientation:portrait) { | |
#container { display:none; } | |
#aviso-vertical { display:block; } | |
} | |
@media only screen and (orientation:landscape) { |
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
# generate key example | |
keytool -genkey -v -keystore maxwal.keystore -alias maxwal -keyalg RSA -keysize 2048 -validity 10000 -dname "CN=Maxwal, OU=Maxwal, S=São Paulo, C=BR" |
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
NSLog(@"[%s:%s:%d]", __FUNCTION__, __FILE__, __LINE__); |
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
<VirtualHost cabine.la:80> | |
ServerAdmin contato@cabine.la | |
ServerName www.cabine.la | |
ServerAlias cabine.la | |
DocumentRoot /var/www/cabine | |
ProxyRequests off | |
<Proxy *> | |
Order deny,allow | |
Allow from all |
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
public void validateApp() | |
{ | |
try { | |
HttpPost request = new HttpPost("http://binho.net/p/teste.json"); | |
List<NameValuePair> nameValuePairs = new ArrayList<NameValuePair>(6); | |
nameValuePairs.add(new BasicNameValuePair("user_email", "positivo@positivo.com.br")); | |
nameValuePairs.add(new BasicNameValuePair("user_password", "123456")); | |
nameValuePairs.add(new BasicNameValuePair("application_id", APP_ID)); | |
nameValuePairs.add(new BasicNameValuePair("device_id", obtemID())); |
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
import os, os.path, shutil | |
YUI_COMPRESSOR = 'yuicompressor-2.4.2.jar' | |
#_______________________________________________________________________ | |
def compress(in_files, out_file, in_type='js', verbose=False, temp_file='.temp'): | |
temp = open(temp_file, 'w') |
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
moment.lang('en', { | |
months : "Janeiro_Fevereiro_Março_Abril_Maio_Junho_Julho_Agosto_Setembro_Outubro_Novembro_Dezembro".split("_"), | |
monthsShort : "Jan_Fev_Mar_Abr_Mai_Jun_Jul_Ago_Set_Out_Nov_Dez".split("_"), | |
weekdays : "Domingo_Segunda_Terça_Quarta_Quinta_Sexta_Sábado".split("_"), | |
weekdaysShort : "Dom_Seg_Ter_Qua_Qui_Sex_Sáb".split("_"), | |
longDateFormat : { | |
LT : "h:mm A", | |
L : "MM/DD/YYYY", | |
LL : "MMMM D YYYY", | |
LLL : "MMMM D YYYY LT", |