docker-compose -f docker-compose.migration.yml run flyway /opt/scripts/migrate.sh
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
| from transformers import AutoTokenizer, AutoModelForCausalLM | |
| import torch | |
| import numpy as np | |
| torch.set_grad_enabled(False) | |
| model_path = "google/gemma-2-2b-it" | |
| access_token = '<your_token>' | |
| tokenizer = AutoTokenizer.from_pretrained(model_path, use_safetensors=True, token=access_token) | |
| model = AutoModelForCausalLM.from_pretrained(model_path, use_safetensors=True, token=access_token, device_map="auto") |
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 unreal | |
| def register(): | |
| menu_owner = "AnimSequenceBoneFixer_AddControlsForSelected" | |
| tool_menus = unreal.ToolMenus.get() | |
| menu = tool_menus.extend_menu('ContentBrowser.AssetContextMenu.AnimSequence') | |
| if (menu): | |
| entry = add_controls_for_selected() | |
| entry.init_entry(menu_owner, |
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
| [alias] | |
| pr = "!f() { \ | |
| open https://github.com/$(git config remote.origin.url | \ | |
| sed -e 's/^https:\\/\\/github.com\\///' -e 's/.git$//')/compare/$(git rev-parse --abbrev-ref HEAD)?expand=1; \ | |
| };f" | |
| [core] | |
| editor = code --wait |
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
| FROM microsoft/dotnet:2.1.300-sdk as base | |
| ARG APP_SOURCE | |
| WORKDIR /app/code | |
| COPY Directory.Build.props /app | |
| COPY ./src/ /app/code/ | |
| RUN dotnet restore ./${APP_SOURCE}/${APP_SOURCE}.csproj |
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
| FROM envoyproxy/envoy:latest as proxy | |
| RUN apt-get update | |
| RUN apt-get -y install curl | |
| CMD /usr/local/bin/envoy -c /etc/service-envoy.yaml --service-cluster servicemain |
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
| public class ControllerContextFilter : IAsyncActionFilter | |
| { | |
| public ControllerContextFilter() { } | |
| public async Task OnActionExecutionAsync(ActionExecutingContext context, ActionExecutionDelegate next) | |
| { | |
| // Sample captures response time for controller/actions | |
| var sw = new Stopwatch(); | |
| sw.Start(); |
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
| using System; | |
| [AttributeUsageAttribute(AttributeTargets.Class, Inherited = true, AllowMultiple = false)] | |
| public class ContractAttribute : Attribute {} |