October 6, 2018 – Building A Startup Experience For The Corewiki | Ubuntober

Folders it’s a one or the other thing I met oh no I butchered your name how should I pronounce.

Your name good is it is it GAD let me know can Andy it can mmm can anybody tell me the github etiquette don’t be a jerk open issues first then submit a pull request Tech Bash is a past event oh you’re right we finished deck bash yesterday i need to clear that out of our events list there you’re right Thank You Shai sharp I should do that let’s do this I’m just going to go to that event folder real quick.

To do de teat yeah images event logo Tech Bash we will move you out it just finished and there we go yep now the events the event.

Deal there is a little bit it’s gonna have a empty space for a minute let’s do that and this that should clean it up alright thirty-eight ninety-eight that’s where we are on the followers count 64 folks watching us right now.

Alright just call you a V not a problem I can do that too bad they force it on you to have windows docker images running who does his VirtualBox and docker for Windows still a no-go due to hyper-v being enabled.

Yeah I think you’re right random dude yes VMware virtual box means no docker in parallel correct alright let’s um here we go let’s open Firefox let’s get over to github.

And take a look at yeah that’s fine and take a look at what’s going on with our core wiki project let’s review some of our pull requests and then let’s write a little bit of.

Code here working on our startup experience so that folks can start to use core wiki a little bit easier and it actually leads into a discussion I was having with some folks at ignite oh did I talk to a lot of folks at ignite from Microsoft there’s an issue that I opened here a while ago let me see if it’s.

Here this one I met with one of the program managers for Microsoft teams and they think this is a really cool idea to demonstrate how you can build a project and connect it as a plugin for teams as another panel the wiki that.

Currently comes with teams is very much single document oriented but if we could enable core wiki as a plugin for teams I think we’re gonna take a look will will will have some fun.

Building that will teach folks how they can integrate their applications with teams the so V I don’t want to be confusing.

Here the team’s team yeah I got that right George thinks this is a neat idea and we’re gonna give this a shot at some point here in the next in the next few months we’ll take a shot at putting in the hooks necessary so that folks can spin up a core wiki tab for their team I think that’ll be fun but we have a couple pull requests that some friends put together for us here and I think we’ll we’ll take a look at integrating I have to build a very simple teams integration for.

Work right now just a basic chat bot Odin ‘red that sounds that sounds like an easy integration I think chat BOTS that type of thing are supposed to be.

Very very easy for folks to connect I haven’t looked at the documentation but it’s one of those one of.

Those simple one of those simpler integrations that they demonstrate is that where we would need the API running um I don’t know about the API but maybe be able to deploy right when somebody says I want a new core wiki tab we deploy a new instance to wherever.

It is in Azure that that makes sense that teams can connect to alright so all of these actually have passed these ones but were just a victim of some reconfiguration of of our build pipeline so let’s take a look at I want to wait on the Azure search I don’t want to wait too much longer because I don’t want that to get away from this let’s take a look at this one welcome.

Form and at bootstrapping to review if this is the best way to for this to be brought in added form to gather information for the JSON config file not wired up so what we started doing in was setting up a secondary configuration file that’ll contain some of the some of the system configuration for our wiki project this way some of those things that are optional that you.

Can configure when you deploy this wiki like database provider surface name maybe your initial theme that you want to be the default those types of things that you want folks to get that are read-only when they come and navigate to it we’ll put those in a separate JSON file so that they’re.

They can be read and written to and reload it easily so ramblin geek I think ramblin geek is here I thought I saw them in the chat room no not right now they were I think they were there anyways so.

Let’s take a look at the changes here so removed my notes here at least the give me.

Your admin bit left my notes up at the top but started filling out a form here that’s pretty good alright and let’s see.

And setting up the layout here to use site theme render body and to include the scripts all right that doesn’t look too bad let’s yes I know checks of Phil just to be I didn’t.

Want to click that button wrong button bad button we don’t want that one go back we like the other button let’s uh let’s take a look at merging this do our first merge here locally on on Linux make sure that everything works right so I’m gonna copy that I only have alright to find I’m going to open you know terminal there we go zoom in just a bit.

Let me go to my core wiki folder I still didn’t get that get that github prompt working quite right yet we need to work on that alright let’s paste in.

Now I should be on now why is it happy on branch dev it should.

Have put me on a different branch what did it do I’ve tried pasting it in.

Project first start is not a commit and a branch cannot be.

Created from it and then it did the git pull rats that’s gonna be a problem alright let’s take a quick look at the log and see where we can backup I want to reset back to origin project first start right okay so if I do a get resets hard and paste that in short they jump there right fantastic okay let’s check out project first arch.

Right so this is a project that I set up this is.

A branch that I set up it’s going to track this part of the wiki that working that we’re working on this current project is you know we have a simple wiki that allows us to create read update and delete articles.

We want to make that first configuration easy for folks to do and that’s what this folder should do for us I don’t trust what’s going on here let’s copy that paste this and switch to a new branch good and now we should pull that in and that should work.

Right that’s what I was looking for I’m gonna run Visual Studio code look at that I’ve got core with you on the brain a type of core instead thanks for highlighting that auto log-in bug yesterday has been driving me crazy for ages amen oh my goodness that was a pain I’m not sure why the what’s going on here with Omni sharp that it’s erroring out.

That feels weird sure looks like it’s loading properly warning and fine you.

Can warn me till you’re blue in the face miss some minutes I see first start integration.

Is going on yes it is turrican we’re gonna be yeah we’re gonna be trying to make that first start easier for folks and then.

Hopefully as we get a little bit further along here and went and it’s easy for folks to do that first start will.

Be able to some bugs never get soft yeah well we’ll be able to have folks set up and build you know simple websites and configure them easy with core wiki just like they do for first thing.

With with WordPress right now except without all that PHP goo alright so I should be able to run the debugger from here and see what this looks like but then I think let me go back to the file list I think we have setup in our startup extensions let’s zoom in there a little I think we should still have.

Set up yet is first start incomplete so we have this hard-coded true and you know I’m gonna put a note here forcing this to true while building.

The functionality in the project.

That’s what a character turn in the project first start branch right and we’ll change that around they added the setting to disable that pop-up did they and I like right click on this or something manage extension yeah yeah I don’t see anything right there’s gotta be a.

Setting that said settings maybe could it be over here no Donna core test Explorer ooh c-sharp configuration to suppress the warning bitnet CLI Zonta now no suppress heat beam Diagnostics hmm which one is it what do you get with areas that you don’t with just a normal folder structure namespace X or H.

Summer um well it gives us a way to isolate everything that’s going on with that group of functionality right so particularly with what we’re trying to do here where we’re bringing in a chunk of functionality that really.

Should only be accessed at the startup of this it’s completely isolate did away from the rest of the application and it doesn’t interfere with things right as I’m developing as I’m building and managing the application going forward this is isolated and I don’t accidentally trip over it it’s the restor warning it’s not the one.

Suppressed on and install so press dotnet restore suppress notification to perform a dot and restore when dependencies this.

One unit test debugging options Omni sharp auto start see but I started the read deal here default default default launch solution and logging level only want warnings mono.

Path path project load timeouts blah blah blah blah.

Blah blah blah blah blah blah wait for word to bugger now that’s all right that’s a lot of settings holy crow.

Still read Rando I wish I could just find the ear or all right can we do a find in this box no results there’s no errors then why am you Turkey I tell you take me over to the bill blog that’s what I will log mean no I.

Want like mmm whatever go away you wouldn’t.

Leave me no all right uh world wake says welcome to the fritz world well thank you welcome it’s great to have you here all right omni sharp is always complaining on the sharp treats warnings as error.

What do you carry our two talked about areas hey dark card i know no js’ to build AP eyes and also no c-sharp and never.

Developed an api is it kind of similar kind of well if you know c-sharp then you you might know a little bit of asp.net disable double in the on the second line of the my comment oh thank you that’s why I have pair programmers who um is there a VMware image that Microsoft ships I don’t think so but let me come back to dark cord you want.

If you want to build a restful api what you can do.

Is you can start up a new asp net application um tell you what let me let’s flip over to the terminal and i can show it a little bit easier over here right and what you you install the.net sdk real easy to get that if you go to dot.

Dot net you can download it from here goes for linux mac and windows and what you’re able to do then is say dotnet new and there’s all kinds of templates available for you in particular it sounds like if you want to build an API you’re going to want there was an API project there it is asp net core web api and then you can write it with C sharp or F sharp by default.

Out of the box when you construct that you’ll end up with a series of controllers and then you extend those controllers to answer the various HTTP verbs that you want to interact with and go forward from.

There it’s actually pretty easy to do.

So and we have done some work in the past in our stream tools project to allow to build an API that can be interacted with using asp.net so you’re welcome darker art that we’re going to be doing some work next week.

On Thursday with that stream tools project particularly around cognitive services consuming those API s and making some api’s available for our bot to interact with so Tuesday I won’t be here I’ll be at angular mix teaching people how to use api’s with angular and then on Thursday I’m going to be I have to I have to drop my daughter off at school and then I’m going to stop at.

The local Microsoft Office for the day and I’ll be with our friend rich Ross live in the studio they’re the two of us on the.

Green screen and we’re going to build we’re gonna work on our our BOTS and we’re gonna do some more work with cognitive services smite Baron Baron asks I’m confused by the dynamic type in c-sharp is it just an object being casted into different types at runtime if I use it as a method parameter is my method considered generic so it sounds like smite barren barren you’re confusing a couple things here let me answer your question.

Then I’ll go back to I’ll go back to our code here and looking at the change that was submitted the dynamic type in c-sharp is actually it’s it’s a type it’s not a generic type generic is something different if I create a method and let’s just stick a method at the end here if I create a method called an A let’s make it static haven’t returned void will call foo and if.

It receives a dynamic type called let’s just call it stuff I can call whatever methods I would like one stuff whether or not it exists or not okay and and at runtime the compiler the Rosalind compiler will figure out if it can actually do those things that will actually look it up inside of a dictionary and see if that that.

Method is there if that property earth is there if that event is there and it can interact with it so if I set up another method here will call this bar right and if I call foo and I pass in hello world that’s okay because that string is that in dynamic and this doesn’t know.

What to do with it right so if I try to get character one off of it var first character equals stuff one that’s okay it doesn’t know whether that’s valid or not but at runtime if stuff isn’t doesn’t have an index or property like that it’ll.

Crash a void dynamic is is a is something that’s recommended with.

C-sharp because it is a statically typed language that’s you know it’s it’s something that it’s there for convenience it’s there if you need it but it can be dangerous.

To use dynamic just like you do with JavaScript write a bunch of unit tests around it to verify that it behaves properly for you or or throw some error handling around it a try catch block.

Around it to ensure that it behaves the way that you expect now that’s different dynamic is different from generics so generics or things where you pass a type in here of some type T right right and we use T is the T is the convention when you.

T is short and English for type right it’s a type that we’re passing in and you know I’m passing in some type of stuff and it doesn’t know what that is I could be doing something to interact with it what you’ll see folks do is they’ll put.

Of a constraint on here that says right where I where I want to do where T new right which is saying right do I need the parentheses there there goes which is saying the type T needs to be able to be constructed so maybe I’m not passing in hello world here maybe I’m passing in a new I don’t know a new dictionary sure okay oh yeah fine I need to give it that type so that’s gonna be confusing not confusing at all so I’m.

Passing that in well stuff actually now if I mouse over it it knows that that’s.

It doesn’t necessarily have an index or it doesn’t understand what that is but I could do something like like say where T.

Is i enumerable okay why do I have requires sure no no I don’t want.

To do ienumerable where t is an i collection that’s come on you’re gonna give me this that’s another generic type I’m gonna be confusing the crap out of this if I go after those aren’t I where T is like I configuration right that’s a bad example you want to put some sort of a constraint on it to ensure that.

Posted in Linux<a href="https://baby2471.com/tag/c" rel="tag">c#</a> <a href="https://baby2471.com/tag/dotnetcore" rel="tag">dotnetcore</a> <a href="https://baby2471.com/tag/linux" rel="tag">Linux</a> <a href="https://baby2471.com/tag/ubuntober" rel="tag">ubuntober</a> <a href="https://baby2471.com/tag/ubuntu" rel="tag">ubuntu</a>