This file contains hidden or 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
function rvc.toggleAIPatrol() | |
isAutoPatrolOn = not isAutoPatrolOn | |
if isAutoPatrolOn and isPlayerDriving then | |
AI.TASK_VEHICLE_DRIVE_WANDER(playerPed, playerVehicle, 30, 0xC00AB) | |
rvc.updateMenus("PATROL MODE - ON", nil) | |
else | |
isAutoPatrolOn = false | |
AI.TASK_PAUSE(playerPed, 1) | |
rvc.updateMenus("PATROL MODE - OFF", nil) | |
end |
This file contains hidden or 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
-- Realistic Vehicle Controls v1.3.1 | |
-- by skyrayfox | |
-- Changelog: | |
-- 1.3.1 | |
-- library hotfix | |
-- 1.3: | |
-- Auto-Drive to waypoint (AI will try to follow all traffic code, press "W,S or Space" to disengage) | |
-- Auto-Patrol the area (AI will randomly drive the vehicle around, following the fraffic code) |
This file contains hidden or 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
{ | |
"Website": [], | |
"default": ["inherit.allow-vpns", "minehq.vpn.bypass"] | |
} | |
{ | |
"Website": [], | |
"default": ["inherit.epic"] | |
} |
This file contains hidden or 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
@admin.register(CustomUser) | |
class CustomUserAdmin(UserAdmin): | |
fieldsets = UserAdmin.fieldsets + (('Custom Info', {'fields': ('account_type', 'address1', 'address2', 'city', 'state', 'zip', 'phone', 'sms_consent', 'onesignal_id',)}),) | |
list_display = UserAdmin.list_display + ('account_type',) | |
list_filter = UserAdmin.list_filter + ('account_type',) | |
icon = '<i class="material-icons">person</i>' |
This file contains hidden or 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
# Squash X commits with an opportunity to update the message headline and body: | |
git reset --soft HEAD~X && | |
git commit --edit -m"$(git log --format=%B --reverse HEAD..HEAD@{1})" |
This file contains hidden or 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
class Profile(TimeStampedModel): | |
user = models.OneToOneField(User, null=True, blank=True, related_name='profile', on_delete=models.CASCADE) | |
organization = models.ForeignKey('home.Organization', null=True, blank=True, on_delete=models.CASCADE) | |
personal_data = models.OneToOneField('PersonalData', null=True, blank=True, on_delete=models.CASCADE) | |
... |
This file contains hidden or 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
@receiver(post_save, sender=User) | |
def create_user_profile(sender, instance, created, **kwargs): | |
# When user is created, build user profile and create payinfo instance. | |
# See also accounts.forms.SignupForm.signup for other signup steps | |
if created: | |
profile = Profile.objects.create(user=instance) | |
profile.payment_info = PaymentInfo.objects.create() | |
try: | |
instance.profile.account_type = AccountType.objects.get(name='Basic') | |
except AccountType.DoesNotExist: |
This file contains hidden or 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
db_1 | PostgreSQL Database directory appears to contain a database; Skipping initialization | |
db_1 | | |
db_1 | 2020-08-07 21:04:53.734 UTC [1] LOG: starting PostgreSQL 12.3 on x86_64-pc-linux-musl, compiled by gcc (Alpine 9.3.0) 9.3.0, 64-bit | |
db_1 | 2020-08-07 21:04:53.734 UTC [1] LOG: listening on IPv4 address "0.0.0.0", port 5432 | |
db_1 | 2020-08-07 21:04:53.734 UTC [1] LOG: listening on IPv6 address "::", port 5432 | |
db_1 | 2020-08-07 21:04:53.738 UTC [1] LOG: listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432" | |
db_1 | 2020-08-07 21:04:53.771 UTC [20] LOG: database system was shut down at 2020-08-07 21:04:52 UTC | |
db_1 | 2020-08-07 21:04:53.775 UTC [1] LOG: database system is ready to accept connections | |
db_1 | 2020-08-07 21:05:24.660 UTC [30] LOG: invalid length of startup packet | |
db_1 | |
This file contains hidden or 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 time | |
import base64 | |
import hashlib | |
import hmac | |
def generate_signature(sig_ingredients: dict) -> str: | |
"""Python 3.6+ implementation of Zoom Signature Generation |
This file contains hidden or 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 { useEffect, useState } from "react"; | |
export function useCustomHookDebugPattern(arg1, arg2, arg3, message, something, setSomething) { | |
// Watch for loop progress | |
const [count, setCount] = useState(1); | |
// Additional local state | |
const [prevMessageId, setPreviousMessageId] = useState(undefined); | |
useEffect(() => { | |
// Increment hook count |
OlderNewer